You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Dec 1, 2023. It is now read-only.
Interceptors can be defined globally and are used for pre- and postprocessing of a request.
157
-
158
-
```js
159
-
Vue.http.interceptors.push({
160
-
161
-
request:function (request) {
162
-
return request;
163
-
},
164
-
165
-
response:function (response) {
166
-
return response;
167
-
}
168
-
169
-
});
170
-
```
171
-
172
-
A factory function can also be used.
173
-
174
-
```js
175
-
Vue.http.interceptors.push(function () {
176
-
return {
177
-
178
-
request:function (request) {
179
-
return request;
180
-
},
181
-
182
-
response:function (response) {
183
-
return response;
184
-
}
185
-
186
-
};
187
-
});
188
-
```
31
+
If you find a bug or want to contribute to the code or documentation, you can help by submitting an [issue](https://github.com/vuejs/vue-resource/issues) or a pull request.
0 commit comments