Skip to content
This repository has been archived by the owner on Aug 11, 2022. It is now read-only.

NPM install a package with dependencies to git repos brings in node_modules #13062

Closed
egucciar opened this issue Jun 15, 2016 · 1 comment
Closed

Comments

@egucciar
Copy link

egucciar commented Jun 15, 2016

Hi,

In npm version 2.13.3, I have a flattened node modules folder and several dependencies in a project which are installed from git.

I have a dependency which itself has git dependencies. These dependencies are also dependencies to the main project.

If I do npm install, the dependency with git dependencies is installing all git dependencies within the packages' node_modules folder

so the tree looks like this:

|_ node_modules
_|_ common_dep_1
_|_ common_dep_2
_|_ package
__|_ node_modules
___|_ common_dep_1
___|_ common_dep_2

This is causing issues with my webpack bundler, since it seems to prefer local npm_modules over the "root" npm_modules. Then the common dependencies are brought into the webpack bundle twice.

How can we resolve this issue? Other than publishing all of our packages to NPM, is there a solution?

Thanks,
Erica

@npm-robot
Copy link

We're closing this issue as it has gone seven days without activity and without being labeled. If we haven't even labeled in issue in seven days then we're unlikely to ever read it.

If you are still experiencing the issue that led to you opening this or this is a feature request you're still interested in then we encourage you to open a new issue. If this was a support issue, you may be better served by joining package.communty and asking your question there.

For more information about our new issue aging policies and why we've instituted them please see our blog post.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants