0

I am trying to build an SPA. I need to use some package lets call it package A. Package A has dependency on package B. Now, I need to change something in package B. I made a fork of package B from GitHub. I also made a fork of package A. How do I tell package A to use my fork of package B? Package.json seems to have only name of the dependency without the source. I searched online but all solutions talk about how to amend single node package and then do PR etc.

Thank you Dan

UPD: Setting package B as a dependency in package A in a format dependency:username/repo#branch-name did not work. It gives the error: npm ERR! package.json Non-registry package missing package.json. Package B fork definitely has package.json

Dan
  • 31
  • 4

1 Answers1

0

As per this answer, Local dependency in package.json you could use a local dependency of package B that fork of package A points to.

Although hard to see, why!? if it's a code change can't be overridden or given an implementation in your own app code?

adrian7
  • 986
  • 12
  • 35
  • I am trying to make some changes to public package. Ultimately I would like to host the app in more environments other than local. Hence, I am trying to host updated package on github – Dan Nov 01 '20 at 12:05