npm switch source address

npm switch source address

1. View the current source address:

npm config get registry

2. The command to switch the source address is as follows:

npm config set registry=http://registry.npm.taobao.org/   //淘宝源
npm config set registry=http://registry.npmjs.org     //npm源

nrm is an npm source mirror manager that can quickly switch npm source addresses

install npm

npm install  nrm -g

Use nrm -V to view the version and whether the installation is successful

nrm -V

Some common commands of nrm


nrm ls 查看所有源地址, *表示当前使用的镜像地址。
nrm add 名称 地址
nrm use 名称(demo)
nrm test 查看链接情况
nrm del 名称

insert image description here

Guess you like

Origin blog.csdn.net/qq_44854653/article/details/127890298