question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

@nrwl/workspace - library cannot be made publishable or at least buildable

See original GitHub issue

Current Behavior

I did encounter this issue earlier today: https://github.com/nrwl/nx/issues/3795

It made me think about the fact that I was probably doing something wrong by having setup some of my shared libs as angular libs (as they were only used in angular projects) but could later on be used by node projects as well.

Therefore, I think I’m going to go ahead and transform those into @nrwl/workspace - library instead of a @nrwl/angular - library. The only thing that is stopping me right now is that I’d have to make that change on quite a few of them and we use the --with-deps flag to build our app so all of our libraries have been made buildable.

Unfortunately, the buildable flag seems to have been made available on all kind of libs except for the @nrwl/workspace - library. Is this by design? Is there anything I’m missing? Or is this a bug?

What should I do?

Expected Behavior

Either being able to import angular libs on a nest app (not the best scenario) or make @nrwl/workspace - library buildable?

Steps to Reproduce

Use nx console and notice that there is no buildable or publishable flag for @nrwl/workspace - library but there is one for the others.

This issue may not be prioritized if details are not provided to help us reproduce the issue.

Failure Logs

Environment

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
maxime1992commented, Jan 8, 2021

I believe this should be kept open

1reaction
juristrcommented, Sep 24, 2020

@maxime1992 I’ll give this a closer look. Will take some time though since I have some higher priority stuff on my plate first. Thx for your patience 🙏

Read more comments on GitHub >

github_iconTop Results From Across the Web

Buildable and Publishable Libraries - Nx
A normal Nx library - let's call it "workspace library" - is not made for building or publishing. Rather it only includes common...
Read more >
nrwl-nx/community - Gitter
But keep in mind, if an app depends on a lib, that lib will be build ... FYI: nrwl/worskspace library doesn't support publishable...
Read more >
MonoRepo + Angular Packaged Libs :: You Can Have Your ...
It appears that the default configuration of the Nx Workspace is not setup to publish your libraries as packages. One of the reasons...
Read more >
Importing a publishable library into another library Fails Angular
My Main tsconfig file contains all the proper imports . I build both the libraries using Angular cli command ng g library <name>....
Read more >
3 - Generating components and Nx lib - Angular and NgRx
nx generate @nrwl/angular:library [name] [options,...] Options: ... --publishable Generate a buildable library. ... UPDATE workspace.json (10310 bytes).
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found