vue+vue-resource+vue-cookie随笔

vue-resource http拦截器interceptors:

Vue.http.interceptors.push(function(request, next) {...}

V-cookie:

request.getHeader("x-requested-with");为null,则为传统同步请求,为 XMLHttpRequest,则为 Ajax 异步请求。

request.headers.set('X-Requested-With', 'XMLHttpRequest');

上一篇:VMware静态地址上网


下一篇:XML与DataSet的相互转换