Resizable Windows
Draggable, resizable 3D windows with audio feedback and haptic responses for XR controllers
XR widgets and utilities for React Three Fiber
import { Canvas } from '@react-three/fiber'
import { XR, createXRStore } from '@react-three/xr'
import { ResizableWindow, SplashScreen, AudioEffects } from 'r3f-xr-widgets'
const store = createXRStore()
function App() {
return (
<>
<SplashScreen store={store}>
<h1>My VR App</h1>
<p>Click Enter VR to begin</p>
</SplashScreen>
<Canvas>
<XR store={store}>
<AudioEffects />
<ResizableWindow position={[0, 1.5, -1]}>
<mesh>
<boxGeometry />
<meshStandardMaterial color="hotpink" />
</mesh>
</ResizableWindow>
</XR>
</Canvas>
</>
)
}