Struggling with creating a publishable NestJS library using NX. Despite reading numerous documentations, I still can't figure it out.
I've developed a NestJS library within an NX monorepository and now I want to publish just this library on NPM, but the process seems unclear.
In the official NX documentation, there's mention of a flag called "--publishable", however, it cannot be used in conjunction with a NestJs library. When attempting to use the flag like this:
ng g @nrwl/nest:library mylib --publishable
An error is returned:
Unknown Option: "--publishable".
Thus, when working with a NestJs library, this flag doesn't function as expected.
Now, I'm trying to create a package.json manually, but I am unsure about the correct steps. Do I need to build the library first before publishing it on npm?
Using the latest NX version!
Any help or guidance would be greatly appreciated!