1.npm --save and --save-dev What is the difference
When called to publish online production environment - to develop locally called development environment, - save that package will go to the line and on-line environment can be used to, for example you npm install a vue-router, the on-line environment also can be used to rely on, so you have to --save ~ vue-loader such as this component is only required when developing compilers like, the line is not required to, so we put the development of --save-dev in just fine ~ ~ ~ ~
2. Install vue axios
axios official document http://www.axios-js.com/
npm install
main.js introduced
vue.use and Vue.prototype. $ xx difference
Three different ways tutorials vue components
Vue classic face questions: Vue.use and Vue.prototype $ xx blood it.?
index.vue used in the page
3.vue deploy apache refresh the page 404
Add pseudo-static -> New File .htaccess file
4. axios concurrent requests
5.axios Global Configuration
Provided the request timeout main.js
Common Configuration Item
Axios create different instances where a project
6.axios package
A single package file request.js
.vue file
View source code editor axios
7.axios interception
Request success / failure to intercept
In response success / failure to intercept
A total of four interceptor
A. To intercept each request
Two interception response
axios instance is an example of the beginning of the article package