前端学习

vue 常见操作

2020-08-12  本文已影响0人  小盐_814e

全局安装vue
https://cli.vuejs.org/zh/guide/

npm install -g @vue/cli
# OR
yarn global add @vue/cli

创建一个新项目

vue init webpack  ”项目名称“

项目相关

# install dependencies
npm install

# serve with hot reload at localhost:8080
npm run dev

# build for production with minification
npm run build

# build for production and view the bundle analyzer report
npm run build --report


快速原型开发
https://cli.vuejs.org/zh/guide/prototyping.html

npm install -g @vue/cli-service-global

创建一个项目

vue create hello-world

在现有的项目中安装插件

vue add eslint

vue 配置参考
https://cli.vuejs.org/zh/config/

上一篇 下一篇

猜你喜欢

热点阅读