`. You don't nest `` inside ``; you nest a geometry and a material inside a mesh.
```typescript
import { Canvas } from '@react-three/fiber';
function Box() {
return (
);
}
export function Scene() {
return (
);
}
```
Read that and the uncanny thing is how _ordinary_ it is. It's components. `` is a component you could reuse, wrap in a list, conditionally render. `rotation` and `color` are just props — drive them from state and the cube animates or recolors, because it's the same reactivity you've used all series. `` is to a 3D renderer what `` is to the DOM renderer: a primitive the renderer knows how to draw. Everything you know about composing React components — props down, state-driven rendering, reuse, hooks — applies unchanged. Only the primitives at the bottom of the tree are different.
## VR and AR Are Just More of the Same Realization
Once you accept that React can describe a 3D scene, VR and AR stop being a separate leap. A VR headset is, from the code's point of view, a 3D scene rendered in stereo with head tracking. AR is a 3D scene composited over a camera feed. The _scene_ — the tree of meshes and lights and cameras — is the same tree React Three Fiber already renders; the WebXR layer adds the headset and the tracking on top.
So the progression is one idea extended, not three separate technologies to learn. Describe a 3D scene as a React tree. Render that tree to a screen — that's 3D on the web. Render it to a headset in stereo — that's VR. Composite it onto the real world — that's AR. At every step the component model is identical; what changes is the output device, exactly the way it changed when we went from browser tab to [desktop window](
) to [native phone](). Same React, different target. You are not learning 3D-React and then VR-React and then AR-React. You are learning that React describes a tree, and the tree can be pointed at increasingly immersive places.
## The Thing This Whole Series Was Actually About
I saved this topic for last on purpose, because it makes the through-line of everything before it visible.
Look back at what we did. We fetched data and let a renderer reconcile the result. We managed state and let components re-render as a function of it. We moved React onto the desktop, onto phones, and now into three-dimensional space — and at every single stop, the _same_ mental model carried: describe what the UI should be for a given state, and let a renderer make it real on whatever the target happens to be. The target was a browser, then a native window, then a native view, then a scene graph. The model never changed. That's not a coincidence you stumble on at article thirty — it's the thing the whole series was quietly teaching under the cover of specific problems.
> React is not a DOM library. It is a way of describing UI as a function of state, with a renderer that reconciles your description against some target. The DOM was always just the first target.
That's why a React developer can move across this entire landscape — web, desktop, mobile, 3D, immersive — without starting over each time. The specifics are real and each one takes genuine learning, as every article in this series insisted. But the foundation is portable in a way that's rare in software, and 3D is the clearest proof: the moment `` becomes `
` and _nothing else about how you think has to change_, you understand what you actually learned. You didn't learn the DOM. You learned React.
## How I'd Approach It — and Where the Series Lands
Strip it to decisions:
- **3D isn't a hack on top of React.** A scene is a tree, React renders trees, and React Three Fiber makes the elements 3D objects. `` is the new ``.
- **Your whole component model transfers.** Props, state, hooks, composition, reuse — all unchanged. Only the leaf primitives differ.
- **VR and AR are the same tree, a different output device.** Screen, headset, camera-composited world. Learn the scene, not three separate stacks.
- **The portable asset was never the platform.** It's the model: UI as a function of state, reconciled by a renderer against a target.
And that's where I'll leave the React Playbook. Thirty articles, from spinning up a project to rendering a cube in VR, and the honest summary of all of them is smaller than the page count suggests: pick tools that own the messy edges, keep your source of truth in one place, treat the client as untrusted and the boundary as sacred, and describe your UI as a function of state so it can follow you to whatever comes next. The specific libraries will churn — some of the ones I recommended will be replaced, and that's fine. The way of thinking is the part that lasts, and if this series left you with that instead of a list of dependencies, it did its job.
Thanks for reading this far. If the Playbook changed how you approach even one of these problems — or if you disagree with where I landed on some of them, which is entirely fair — I'd genuinely like to hear about it. That's the conversation that makes writing thirty of these worth it.