Angular Elements - Are they a lib or an app in NRWL/NX?

Viewed 1435

Trying to build a suite of angular elements (web components) in an NX workspace.

I tried first as a lib, but couldn't 'build'. I retried as an app - but I cannot create a storybook for it since its not a lib.

What's the path to peace?

1 Answers

I think the answer is to make a publishable lib:

ng g @nrwl/angular:lib my-elements --publishable

This will create a library with the build architect to your workspace file, which is what you need to run ng build my-elements.

Related