This section describes how this monorepo can be handled.
- Install the latest version of NodeJS
- Clone or download this repository
- Install yarn globally:
npm install yarn -g
- Install lerna globally:
npm install lerna -g
- Open console and move into project folder, run:
lerna bootstrap
To run the web app with hot module reloading at //localhost:9000
, run:
\Foo\Bar\MonorepoRootFolder> yarn run start:spa
To run the mobile app with hot module reloading on android device emulator, run:
\Foo\Bar\MonorepoRootFolder> yarn run start:android
Following scripts are executed for every sub repository via lerna.
Be aware that these commands require yarn and lerna as a global dependency.
Due to limitations of the react-native the src/mobile-app
package is not yet integrated as a yarn workspace
and has no lerna management support in this project.
To install install node_modules
in every package, run:
lerna bootstrap
To remove node_modules
from all packages (mobile-app excluded), run:
lerna clean
To run all package tests (mobile-app excluded), run:
yarn run test
To type check every package, run:
yarn run tsc
To test linting for every package, run:
yarn run lint
To fix linting for every package, run:
yarn run lint:fix
To execute tests, type check, lint fix and build every package, run:
yarn run ci