A collection of samples using a ClojureScript / React-Three-Fiber stack.
To create a new project, copy the template
project directory :
cp -R template/ my-project
A project can be started by entering its directory and running the start
command :
cd my-project
npm run start
This will install dependencies, build the files and start a live server. You can then visit localhost:8080 to run the app locally.
The template use the following npm
libraries :
- react & react-dom
- react-spring/three
- react-three (fiber, drei, postprocessing)
- three
and the following Shadow-cljs
packages :
- After compilation the browser may sometimes fails to render the app. If it happens try either to refresh your browser or to trigger the live compilation until it renders again.
- The package
regenerator-runtime
is required forreact-spring
andreact-three/*
to work. - At the moment some dependencies fail to compile using a
shadow-cljs
version above2.14.x
.
- ClojureJS cheatsheet
- ReactJS cheatsheet
- ShadowCLJS Users Guide
- Reagent
- Reagent React Features
- InteropWithReact
- React Spring
- THREE.js (using v0.137.0)
- THREE.js performance tips
- react-three/fiber (using v7.0.3)
- react-three/drei (using v7.27.5)
- react-three/postprocessing
- react-three-fiber examples
- cljs-react-three-fiber
- racing-game-cljs
- R3F in practice
This project is released under the MIT License.