Working on the PDM
The PDM is one repository with Yarn workspaces.
| Package | What it is |
|---|---|
packages/api | NestJS 11 on Postgres with TypeORM. Migrations in src/database/migration |
packages/web | Vite and React 18 |
packages/worker | The job worker |
packages/generator-sdk | @classcad/pdm-generator |
packages/version-graph | Lays out and draws the history graph |
packages/dev | yarn dev: embedded Postgres, the ClassCAD mock and the sample data |
packages/buerligons | The editor, a git submodule of Buerligons |
Commands
yarn dev # everything, with stand-ins and sample data
yarn test # unit tests
yarn test:e2e # the API against a real Postgres (yarn db:up first); the worker is simulated
yarn lint
The editor
Buerligons is the submodule packages/buerligons, compiled from source into the web app. yarn checks it out. To change it, commit and push inside the submodule, then commit the new pointer in the PDM.
The ClassCAD mock
yarn dev answers ClassCAD calls with what the real engine made of the sample models: their measures and pictures, kept in packages/dev/fixtures. A model is recognised by its SHA-256, so a changed sample model needs a new capture with the real engine. The fixtures' README says how.
Design notes
doc/ in the repository holds the design notes behind the PDM: versions and branches, references, code documents, the editor. They're in German.