7

I know there are subtle differences between yarn and npm. Now I have a library managed with yarn and an app managed with npm.

Should it work without issues, if I create a linked pkg in my lib directory via yarn and apply it via npm in my other directory? Or should I expect issues with this setup? If yes, which issues might pop up and how could I avoid them (except converting both projects to the same manager)

~/the-lib$ yarn link 
~/app$ npm link @the/lib
helt
  • 4,925
  • 3
  • 35
  • 54

1 Answers1

0

This is a year old, but I stumbled across it while trying to answer this for myself. Here's my setup:

  • library package: NPM
  • client package: YARN

When I tried using npm and yarn as described in the question it did not work.

But, I was able to run yarn link successfully in my npm package, and then yarn link lib-name in my client package.

So, it works!

ndp
  • 21,546
  • 5
  • 36
  • 52