three-viewer-react
v1.0.12
Published
``` ts import { ThreeViewer,ThreeViewerRef } from 'three-viewer-react/build';
Downloads
37
Readme
three-viewer-react
import { ThreeViewer,ThreeViewerRef } from 'three-viewer-react/build';
export interface IDemoProps{
}
export interface IDemoRef {
}
const Demo=forwardRef<IDemoRef,IDemoProps>((props,ref)=>{
const viewerRef = useRef<ThreeViewerRef>(null);
useEffect(()=>{
// 添加3D对象
// viewerRef.current?.addObject3D(...);
},[]);
return <ThreeViewer ref={ref}/>;
});