- have lerna installed globally
npm i -g lernaor usenpx - install all dependencies
npx lerna bootstrap - from the root, run
npm ito install some common dev packages and also set up git hooks automatically - create
.envfile in each package, based on the package's.env.examplefile - to launch the api and client, run
npm startin each application
- add new packages with
npx lerna create <package-name> - to install a local dependency specifically for one package, run
npx lerna add --scope=<your-package> <package-name>
Pre-commit hooks use native Git hooks. The following should be done for hooks to work:
- ensure the
pre-commithook file ingit-hooksdirectory is executable - ensure your git config knows about the
git-hooksfolder. If needed, rungit config core.hooksPath ./git-hooks(done automatically after you donpm installin the root).