Commands
npm run dev # Vite dev server
npm run dev:site # one origin over the editor and scm-sim (above)
npm run build # tsc -b (the type-check) + vite build → dist/
npm run preview # serve dist/ locally
npm run lint # oxlint, with the React hook rules; does not type-check
npm test # vitest, a few seconds, no browser
npm run test:watch
npm run test:maps # write tests/maps again from the code that makes them
npm run test:e2e # the browser tests, against dist/ (build first)
npx vitest run tests/chk.test.ts # one file
npx vitest run -t "flood fill" # tests matching a name
npm run extract # game data from a classic installation → public/
npm run check:assets # what game data is on disk
npm run i18n # check the translations against the source (-- --write updates them)
npm run docs:reference # rewrite the generated tables of the trigger and CHK references
npm run build:docs # the documentation site → docs-site/
npm run vendor:plugins # bring plugins/ up to date (predev and prebuild run it)
npm run bundle:runtimes # copy the default plugins' runtimes into dist/ (desktop and image builds)
npm run build:plugin-types # the plugin typings → plugin-api/
npm run desktop # run the desktop app against dist/
npm run build:desktop # installers for this OS → release/
npm run build:image # the container image, tagged scmjs
npm run build is the type-check: tsc -b covers the app, the scripts and the desktop
main process (tsconfig.app.json, tsconfig.node.json, tsconfig.desktop.json). The app
config is strict: noUnusedLocals, noUnusedParameters, verbatimModuleSyntax (so
import type for types) and erasableSyntaxOnly (so no enums and no constructor
parameter properties). Lint, the tests and the build run on every pull request and every
push to main.