Package.json
We make use of the npm-run-all package to help split up the scripts, so that we can reuse them. For example, if we have scripts test:one
, test:two
, test:three
and then run npm-run-all --sequential test:*
, then each of the scripts that start with "test:" would run one at a time.
What do they do?
I will admit, there are a lot of scripts and dependencies. It would take far too much maintenance to keep documentation about each script up to date. So lets keep it simple, with the knowledge of the npm-run-all package we use, here are some important scripts
npm run setup
- All scripts that are important for getting the the developer environment readynpm run build
- Generate the output of one or more projects within this solutionnpm run data:<id>
- _Various data projects,npm run data:downloader
is used by FormData, to download all the data from the database and write them to disk in the correct format.npm run data:interactive
is used to quickly run functions from an interactive console
npm run storybook
- Storybook tasksnpm run docs
- Documentation generationnpm run test
- Unit tests and coverage reportsnpm run db:generate
- Generate contracts from the database provider (Xata.io)