nrm 可以快速切換鏡像源,還可以測試自己網絡訪問不同源的速度
*安裝 nrm
npm install -g nrm
- 列出當前可用的所有鏡像源
nrm ls
* npm -------- https://registry.npmjs.org/
yarn ------- https://registry.yarnpkg.com/
cnpm ------- http://r.cnpmjs.org/
taobao ----- https://registry.npm.taobao.org/
nj --------- https://registry.nodejitsu.com/
npmMirror -- https://skimdb.npmjs.com/registry/
edunpm ----- http://registry.enpmjs.org/
- 使用淘寶鏡像源
nrm use taobao
- 測試訪問速度
nrm test taobao