axios配置请求头

119 阅读1分钟

靠人不如靠自己如果后端懒不要抱怨自己改

axios.defaults.withCredentials=true axios.defaults.crossDomain=true axios.defaults.headers.post['Content-Type'] = 'multipart/form-data;charset=utf-8' axios.defaults.headers.get['Content-Type'] = 'application/x-www-form-urlencoded'