1.在控制台输入命
npm config get registry
输出默认地址为:https://registry.npmjs.org/
2.修改为阿里镜像地址命令:
npm config set registry https://registry.npmmirror.com/
通过npmconfig命令,可以查看和设置npm的默认注册表。默认情况下,npm的registry是https://registry.npmjs.org/。若要改为阿里镜像地址,可以使用命令`npmconfigsetregistryhttps://registry.npmmirror.com/`,这样可以加速npm包的下载速度。
npm config get registry
输出默认地址为:https://registry.npmjs.org/
npm config set registry https://registry.npmmirror.com/
1万+
4957
5214
1802

被折叠的 条评论
为什么被折叠?