Certificate has expired(npm 安装strapi)

报错信息

解决方法

1、清空缓存,有时,损坏的缓存会导致连接问题

npm cache clean --force

2、切换到淘宝镜像源的 npm 注册表

npm config set registry https://registry.npmmirror.com/

执行这两步后就可以执行自己想要安装的东西了,我是在执行npx create-strapi-app schedul命令创建strapi项目时报上述错误。仅供参考。

当然再安装好后你可以切换回官方注册表,命令如下。

npm config set registry https://registry.npmjs.org/

相关推荐
行星0082 天前
mac 通过homebrew 安装和使用nvm
macos·npm·node.js
xrkhy3 天前
nvm安装详细教程(卸载旧的nodejs,安装nvm、node、npm、cnpm、yarn及环境变量配置)
前端·npm·node.js
领创工作室3 天前
npm介绍,指令合集,换源指令
前端·npm·node.js
小妖6664 天前
npm run 命令传递参数
前端·npm·node.js
Hilaku4 天前
深入理解npm、pnpm和yarn的lock文件,我发现了一些细节
前端·javascript·npm
mon_star°5 天前
有趣的 npm 库 · json-server
前端·npm·json
yourkin6669 天前
npm run 常见脚本
前端·npm·node.js
我不是李.杨10 天前
解决 npm i node-sass@4.12.0 安装失败异常 npm i node-sass异常解决
rust·npm·sass
艾小码10 天前
三大 Node.js 包管理器对决:npm、yarn、pnpm 深度横评
npm·yarn
金金金__11 天前
无废话,直接干,一篇短篇教你利用Corepack安装Yarn~
npm·yarn