Working with the Web App
development environment
https://bun.sh/docs/installation)
Requires Bun (curl -fsSL https://bun.sh/install | bash
Install the dependencies
bun install
Run the Vite development server
Note that you should run the Flask application separately (on port 5000) to serve the API.
bun run start
Releasing & building a production bundle
Run the following command to build a production bundle:
bun run build
This will build the new bundle and deploy it to
compendium_v2/static/*
. This should be committed to the repository.
Linting/Formatting
For the Flask app, use pep8 (autopep8 in vscode) with a max line length of 120. The frontend (compendium-frontend) uses eslint for linting checks, and some formatting rules are enforced.
The build of the frontend is gated by a linting check, to fix anything auto-fixable, use:
bun run lint:fix