工具 | 版本要求 |
---|---|
Node.js | 14.20.0 |
npm | 6.14.7 |
Vue CLI | 5.0.8 |
由于淘宝原镜像域名(registry.npm.taobao.org)的HTTPS证书已到期,现需切换至新域名(registry.npmmirror.com)。
# 1. 设置新镜像源
npm config set registry https://registry.npmmirror.com
# 2. 验证配置是否生效
npm config get registry
# 预期输出: https://registry.npmmirror.com
# 1. 清理npm缓存
npm cache clean --force
# 2. 更新镜像源地址
npm config set registry https://registry.npmmirror.com
如果不想手动更新镜像源,可以直接使用淘宝的cnpm工具,官方已自动处理了镜像源更新问题。
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号