This monorepo is the home of the okokok designsystem. It contains okokok elements – the component library for okokok, the okokok icon library, themes ("okokok" is the default theme for elements) and designtokens which contain all the colors, sizes, fonts, icons, etc. that are used throughout the whole okokok ecosystem.
The app documenting all libraries is hosted under /src/app/designsystem The component library called @okokok/elements is hosted under /src/libs/elements.
- Run
nx serve
to start the development server serving the default project which isdesignsystem
. Navigate to http://localhost:4200 - Make some changes to an existing component
- See the design system automatically reflect your changes.
- Commit your changes
To create a new component run nx g component [componentname] --project=@okokok/components --export
. The new component is scaffoled into the folder /src/lib/components
.
10-minute video showing all Nx features
Run ng g @nrwl/angular:app my-app
to generate an application.
You can use any of the plugins above to generate applications as well.
When using Nx, you can create multiple applications and libraries in the same workspace.
Run ng g @nrwl/angular:lib my-lib
to generate a library.
nx g lib --importPath=@okokok/mylib --name=mylib --tags=scope:mylib
You can also use any of the plugins above to generate libraries as well.
Libraries are shareable across libraries and applications. They can be imported from @okokok/mylib
.
Run ng serve my-app
for a dev server. Navigate to http://localhost:4200/. The app will automatically reload if you change any of the source files.
Run ng g component my-component --project=my-app
to generate a new component. The new app will be scaffoled in the /src/app
folder.
Run ng build my-app
to build the project. The build artifacts will be stored in the dist/
directory. Use the --prod
flag for a production build.
Run ng test my-app
to execute the unit tests via Jest.
Run nx affected:test
to execute the unit tests affected by a change.
Run ng e2e my-app
to execute the end-to-end tests via Cypress.
Run nx affected:e2e
to execute the end-to-end tests affected by a change.
Run nx graph
to see a diagram of the dependencies of your projects.
Visit the Nx Documentation to learn more.
This project was generated using Nx.
🔎 Smart, Fast and Extensible Build System