Answer the question
In order to leave comments, you need to log in
What is the correct way to bundle npm packages locally during development?
There is a main project. Packages are being developed for it. Lots of packages. Packages are dependent on other similar locally developed packages.
So far, the only simple way I know how to link packages with the main project and between themselves is to prescribe yarn link
and thereby create a link in node_modules to the directory of the included package. But this method is not very pleasant. He seems to be quite a crutch.
Share your experience, how do you think it is more optimal to develop such packages?
PS I'll clarify right away that pushing every change in a local project to git just to start the main project and check the package's performance is not very optimal :)
Answer the question
In order to leave comments, you need to log in
https://github.com/lerna/lerna or https://docs.npmjs.com/cli/v7/using-npm/workspaces/
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question