Installing past or future versions of npm packages


npm lets you install versions of packages other than the current one, via:



npm install «package-name»@«tag»
npm install «package-name»@«version»


Installing tags

Tags are aliases for versions. You can look up available tags via:



npm view «package-name» dist-tags

Example:



$ npm view webpack dist-tags
{ latest: '1.12.9', beta: '2.0.1-beta' }

Installing versions

You can look up available versions via:



npm view «package-name» versions

Example:



$ npm view webpack versions

[ '0.1.0',
'0.1.1',
···
'1.12.8',
'1.12.9',
'2.0.0-beta',
'2.0.1-beta' ]

Comments

Popular posts from this blog

Steve Lopez and the Importance of Newspapers

Ideas for fixing unconnected computing

Omar to kill me