Skip to content

Repository files navigation

Rigid Body Precession

CI

A reusable single-screen simulation template built with SceneryStack, Vite 8, TypeScript 7, and Biome 2.

Features

  • Single-screen SceneryStack scaffold with model/view separation
  • English, Spanish, and French localization via StringManager
  • Default and projector color profiles
  • Progressive Web App (installable, offline-capable)
  • Git hooks for Biome pre-commit checks
  • Shared GitHub Actions CI via OpenPhysics/Baton

Quick Start

npm install
npm run icons # generate PNG icons from public/icons/icon.svg
npm start # dev server → http://localhost:5173

Scripts

CommandDescription
npm start / npm run devStart Vite dev server
npm run buildType-check + production build → dist/
npm run previewPreview the production build locally
npm testRun Vitest unit tests (includes memory-leak suite)
npm run test:fuzzOptional Playwright fuzz smoke (?fuzz, default 15s)
npm run test:fuzz:quickShorter fuzz smoke (10s)
npm run checkTypeScript type check
npm run lintBiome lint check
npm run formatAuto-format all files
npm run fixLint + auto-fix
npm run iconsRegenerate PNG icons from public/icons/icon.svg
npm run cleanRemove dist/

New sims start at version: "0.0.0" in package.json. Bump only when cutting a release (for example npm version patch and a matching git tag). Keep name in kebab-case; it is separate from the SceneryStack sim identifier in src/init.ts.

Tech Stack

ToolVersionPurpose
SceneryStack^3.0.0Simulation framework
Vite^8Build tool + dev server
TypeScript^7Type-safe JavaScript
Biome^2.5Linting + formatting
vite-plugin-pwa^1PWA + service worker

License

GNU Affero General Public License v3.0 — see OpenPhysics org license.

Contributing

See OpenPhysics contributing guidelines. Report bugs via GitHub Issues; use org issue templates.

About

Rigid-body dynamics of a spinning gyroscope: steady precession under gravity, nutation, and torque-free tumbling.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages