We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ecfcb24 commit fa3dc51Copy full SHA for fa3dc51
README.md
@@ -1,2 +1,34 @@
1
# vue-axios
2
A small wrapper for integrating axios to Vuejs
3
+
4
+## How to install:
5
+### CommonJS:
6
+```
7
+npm install --save axios vue-axios
8
9
10
+And in your entry file:
11
12
+import Vue from 'vue'
13
+import axios from 'axios'
14
+import VueAxios from 'vue-axios'
15
16
+Vue.use(VueAxios, axios)
17
18
19
+### Script:
20
+Just add 3 script in order: `vue`, `axios` and `vue-axios` to your `document`.
21
22
+## Usage:
23
+This wrapper bind `axios` to var `Vue` or `this` if you're using single file component.
24
25
+You can `axios` like this:
26
27
+Vue.axios.get(api).then((response) => {
28
+ console.log(response.data)
29
+})
30
31
+this.axios.get(api).then((response) => {
32
33
34
0 commit comments