I just created my package and published it to artifact registry.
This package has postinstall
script that works if I do npm i
inside package directory, even if there is no node_modules
directory.
Inside postinstall
script I use patch-package
from npm to overwrite few dependencies.
The problem is when I install this package in other project with npm i -s @my/package
.
When postinstall
script is executing it doesn`t find those packages and throw errors.
I tried to execute patch-package
in parent directory but it does not find those packages anyway.
Any idea what I can do to fix this?
To fix problem I added in
postinstall
script installation script for those packagesnpm i [email protected] [email protected] [email protected] && rest...
.