0

I have an angular library with multiple secondary entry points: a and b.

I do also have some code which is shared accross a and b. The shared code is located in another secondary entry point shared.

From my knowledge I must have a secondary entry point for the shared code, otherwise build will fail with a message like File xxx is not under 'rootDir' xx. 'rootDir' is expected to contain all source files.

With this setup the build does succeed. However in my dist I find a, b and shared. I don't want that consumers of the lib can use shared.

How to exclude it from distribution? Alternatively can I share code between secondary entry points from a source which is not a secondary entry point?

Mikelgo
  • 483
  • 4
  • 15

0 Answers0