Vue quickly build project

1, Windows installation package (.msi) node installation
32 Download installation package:  https://nodejs.org/dist/v4.4.3/node-v4.4.3-x86.msi
64 Download installation package:  https://nodejs.org/dist/v4.4.3/node-v4.4.3-x64.msi
2. Check node version: node --version
3. ensure that the environment there webpack:
Global Installation: npm install -g webpack 
Development Environment Installation: npm install --save-dev webpack
4. Global # scaffolding tool mounting vue-cli    
   npm install -global vue-cli
 # Create a new project based on a template webpack     
  vue init webpack my-project
5. Installation depends    
 cd my-project     
 npm install    
 npm run dev
6. expand installation
npm i vue-resource --save
npm i axios --save
7. # Create views folder under the src directory for managing the components   
 # Main.js inlet file, the global import (import from) and registration ( Vue.component ) and using (Vue.use) write here, the method may be extended (Vue.prototype.axios = axios) on the prototype of Vue           
# Configure routing in the router file           
# Write common components in the components file

Guess you like

Origin www.cnblogs.com/linjiu0505/p/11549372.html