Using Angular CLI v6, we are able to create library or small application inside a Angular CLI generated application.
ng new lib-projectcd lib-projectng g library logger-libng g application playground-appng serve --project playground-appng build --project logger-lib
If for example, the lib logger-lib, we only want to use inside our organization or we want to publish to local registry.
The library we can use:
sudo npm i -g vardaccio
Run:
vardaccio
Do the lib build:
ng build --project logger-libcd dist/logger-libnpm publish --registry http://localhost:4873