Sample app showing three.js with rapier physics

I have created a small sample app demonstrating how to integrate three.js with the Rapier physics engine:

The app is meant to be a starting point for people who want to create a serious app or game - all of the code conforms to commercial industry coding practices (it includes eslint, prettier support, etc. - although no unit tests yet), is written entirely in TypeScript, and uses the super-fast Vite bundler. It includes extensive explanatory comments.

It even contains experimental support for hot-reloading of the renderer using Vite’s API - hit save in the editor and it will reload the engine and restart the 3D scene, without reloading the entire browser page.

2 Likes