1 vue create 项目名
![](https://img.haomeiwen.com/i1511884/b6b2be180d5a7c64.png)
2 选择自定义项目
? Check the features needed for your project: (Presee <space> to select,
<a> to toggle all, <i>to invert selection)
>(*) Babel
( ) TypeScript
( ) Progressive Web App (PWA) Support
(*) Router
(*) Vuex
(*) CSS Pre-processors
() Linter / Formatter
( ) Unit Testing
( ) E2E Testing
Babel:Babel配置(Babel是一种JavaScript语法的编译器)。
TypeScript:一种编程语言。
Progressive Web App(PWA)Support:渐进式Web应用支持。
Router:vue-router。 路由可选
Vuex:Vue状态管理模式。 存储可选
CSS Pre-processors:CSS预处理器。
Linter/Formatter:代码风格检查和格式化(尽量不要,会报各种错)。
Unit Testing:单元测试。
E2E Testing:端到端(end-to-end)测试。
3 项目创建完成后,执行如下命令进入项目目录,启动项目:
cd hello-vue
npm run serve
4 项目启动后,会默认启动一个本地服务,如下所示:
App running at:
- Local: http://localhost:8080/
网友评论