3d-viewer/app/components/Map.tsx
2025-02-26 09:46:13 +01:00

16 lines
421 B
TypeScript

"use client";
import { useEffect, useRef } from "react";
import { init } from "../three/utils/init";
import { initSimple } from "../three/simple-example";
export function Map() {
const divRef = useRef<HTMLDivElement>(null);
useEffect(() => {
if (!divRef.current) return;
init(divRef.current);
//initSimple(divRef.current);
}, [divRef]);
return <div className="w-full h-full" ref={divRef}></div>;
}