npm Community Forum (Archive)

The npm community forum has been discontinued.

To discuss usage of npm, visit the GitHub Support Community.

Feature request - declare dependencies as "local" - don't install them, instead npm link them

Feature request - declare dependencies as “local” - don’t install them, instead npm link them.

What that might mean is, before:

{
  "dependencies": {
     "suman": "latest"
 }
}

after:

{
  "localDependencies: {
    "suman": "link"
 },
  "dependencies": {
     "suman": "latest"
 }
}

if a certain npm config was set, npm install would would not install suman, it would run npm link suman after the install completed. IT would be a lot more efficient for large dependencies.


This is already covered by npm@5 and later, using file: – we no longer pack repositories. We in fact just symlink them.

For a more detailed approach to the overall temporary symlink problem, see New npm link command


nah, file:// doesn’t work zkat, because that’s hardcoded in dependencies. The addition of “localDependencies” is the key idea here. please re-think this.