NPM 仓库切换淘宝源

淘宝镜像站

https://npmmirror.com/

在项目下创建 .npmrc 和 .yarnrc

.npmrc 文件如下

loglevel=http
progress=false

registry=https://registry.npmmirror.com

sass_binary_site=https://npmmirror.com/mirrors/node-sass/
phantomjs_cdnurl=https://npmmirror.com/mirrors/phantomjs/
electron_mirror=https://npmmirror.com/mirrors/electron/
sqlite3_binary_host_mirror=http://npmmirror.com/mirrors/
profiler_binary_host_mirror=http://npmmirror.com/mirrors/node-inspector/
chromedriver_cdnurl=https://npmmirror.com/mirrors/chromedriver
sentrycli_cdnurl=https://npmmirror.com/mirrors/sentry-cli/

.yarnrc 文件如下

registry "https://registry.npmmirror.com"

sass_binary_site "https://npmmirror.com/mirrors/node-sass"
phantomjs_cdnurl "https://npmmirror.com/mirrors/phantomjs"
electron_mirror "https://npmmirror.com/mirrors/electron/"
sqlite3_binary_host_mirror "https://npmmirror.com/mirrors"
profiler_binary_host_mirror "https://npmmirror.com/mirrors/node-inspector/"
chromedriver_cdnurl "https://npmmirror.com/mirrors/chromedriver"
sentrycli_cdnurl "https://npmmirror.com/mirrors/sentry-cli/"
最后修改:2022 年 04 月 22 日 10 : 41 PM

发表评论