2.0 KiB
DAFA-web
The project was generated using Nx.
Quick Start & Documentation
For all commands we will refer to the npm scripts located inside package.json. When using these commands, you do not need to have @angular/cli installed globally on your computer.
To get started, clone the repository and run npm install in the root of the project, this will install all dependencies.
Development server DAFA-web
Run npm run start:dafa for a dev server. Navigate to http://localhost:4200/. The app will automatically reload if you change any of the source files.
Generate an application
Run npm run new-app my-app to generate an application. When using Nx, you can create multiple applications and libraries in the same workspace.
Generate a library
Run npm run new-lib my-lib to generate a library. Libraries are shareable across libraries and applications. They can be imported from @dafa-web-monorepo/mylib.
Code scaffolding
Run npm run new-component my-component --project=my-app to generate a new component.
Build DAFA-web
Run npm run build:dafa to build the project. The build artifacts will be stored in the dist/ directory. Use the --prod flag for a production build.
Running unit tests on DAFA-web
Run npm run test:dafa to execute the unit tests via Jest.
Run npm run nx affected:test to execute the unit tests affected by a change.
Running end-to-end tests on DAFA-web
Run npm run e2e:dafa to execute the end-to-end tests via Cypress.
Run npm run nx affected:e2e to execute the end-to-end tests affected by a change.
Understand your workspace
Run npm run nx dep-graph to see a diagram of the dependencies of your projects.
Using the mock-api