Linked to from http://lukecod.es/2015/12/04/npm3-top-level-nested-conflicting-dependencies/
In npm3 conflicting versions of shared sub-dependencies will end up at the top level based on which is installed first.
This isn't a problem, just something to be aware of in case you are relying on something being at the top of node_modules
(which you really shouldn't be).
inhertits-1.tgz
depends on inherits@^1.0.2
and inherits-2.tgz
depends on inherits@^2.0.1
The scripts
in package.json install them in different orders and then display the version from node_modules/inherits/package.json
.
# npm i inherits-1.tgz && npm i inherits-2.tgz
> npm run order1
"version": "1.0.2"
# npm i inherits-2.tgz && npm i inherits-1.tgz
> npm run order2
"version": "2.0.1"
# npm i inherits-1.tgz inherits-2.tgz
> npm run order3
"version": "1.0.2"
# npm i inherits-2.tgz inherits-1.tgz
> npm run order4
"version": "1.0.2"