npm 淘宝镜像到期

npm 淘宝镜像到期了

npm ERR! request to https://registry.npm.taobao.org/cnpm failed, reason: certificate has expired


npm ERR! code CERT_HAS_EXPIRED
npm ERR! errno CERT_HAS_EXPIRED
npm ERR! request to https://registry.npm.taobao.org/cnpm failed, reason: certificate has expired

npm ERR! A complete log of this run can be found in: D:\nodejs\node_cache\_logs\2024-01-23T11_00_28_143Z-debug-0.log

将npm淘宝镜像切换至淘宝的新镜像域名

// 1. 清空缓存
npm cache clean --force
// 2. 切换新源
npm config set registry https://registry.npmmirror.com
// 3. 查看源是否设置成功
npm config get registry



参考:

npm 淘宝镜像到期了,尽快切换(npm使用淘宝镜像安装时报错)

你可能感兴趣的:(#,vue,npm,前端,node.js)