Motivation ("The Why")
It's very bad for different users prefer different registries globally, I accidentally commit unexpected changes several times.
Example
FYI, yarn 2+ and pnpm don't store registry info in their lockfile.
How
Current Behaviour
Read it from .npmrc instead.
Desired Behaviour
As title, registry should not be stored into package-lock.json, it would also make package-lock.json much smaller.
References
Motivation ("The Why")
It's very bad for different users prefer different registries globally, I accidentally commit unexpected changes several times.
Example
FYI,
yarn2+ andpnpmdon't store registry info in their lockfile.How
Current Behaviour
Read it from
.npmrcinstead.Desired Behaviour
As title,
registryshould not be stored intopackage-lock.json, it would also makepackage-lock.jsonmuch smaller.References
yarn: https://yarnpkg.com/configuration/yarnrc#npmRegistryServerpnpm: https://pnpm.io/settings#registry--authentication-settings