欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

执行 npm install -g @vue/cli 报错

程序员文章站 2022-05-30 14:41:30
...

目录

一、问题描述 

二、解决方案

1、升级npm

2、清理缓存 

3、再次安装


一、问题描述 

准备使用vue3.0初始化一个项目,在使用 npm install -g @vue/cli 安装过程出现了异常信息:

npm WARN deprecated @hapi/[email protected]: Switch to 'npm install joi'
npm WARN deprecated [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated @hapi/[email protected]: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/[email protected]: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated [email protected]: this
npm WARN deprecated [email protected]: Please see https://github.com/lydell/urix#deprecated

二、解决方案

1、升级npm

npm i -g npm

2、清理缓存 

npm cache clean --force

3、再次安装

 npm install -g @vue/cli