执行下列命令打开配置编辑

    1. npm config edit

    找到 registry 并设置源地址

    1. registry=https://registry.npmmirror.com

    或者直接打开 https://npmmirror.com/ 参照