npm install -g @vue/cli //按照脚手架依赖
vue -V //查看vue脚手架版本
升级vue脚手架版本
npm install -g @vue/cli
npm uninstall -g vue-cli
vue create ”项目名称“
Project name ==> 项目名称 自己输入;
Project description ==> 项目描述 自己输入;
Author ==> 项目作者 自己输入;
Vue build ==> 打包方式,回车即可;
Install vue-router ==> 是否要安装 vue-router,项目中肯定要使用到 所以Y 回车;
Use ESLint to lint your code ==> 是否需要 js 语法检测 目前我们不需要 所以 n 回车;
Set up unit tests ==> 是否安装 单元测试工具 目前我们不需要 所以 n 回车;
Setup e2e tests with Nightwatch ==> 是否需要 端到端测试工具 目前我们不需要 所以 n 回车;
新版需要选择运行依赖安装方式选择第三个 方便不费时
Should we run npm install for you after the project has been created? (recommended)
Yes, use NPM
Yes, use Yarn
> No, I will handle that myself
4、进入项目,安装依赖
进入到项目路径下,进行依赖安装
[
](https://blog.csdn.net/Li_Wen_Zhong/article/details/121380777)
npm install
输入 npm run dev,启动项目,
npm run serve