Starting with npm@6.9.0 you can install the package under an arbitrary module name. npm@6.9.0 provides support for package aliases.
To set tarball under an arbitrary module name, use the custom-name@tarball-url argument, for example, set a special express tarball as my-express module:
npm i my-express@https ://github.com/expressjs/express/archive/4.16.3.tar.gz
This feature also allows you to create aliases for packages published in the npm registry:
npm i express@npm :@my-scope/express
source share