I made a login in vue, and after logging in successfully, I should receive a cookie. But no cookie was received.
Axios global settings
import axios from "axios"
Vue.prototype.$axios = axios
axios.defaults.crossDomain = true;
axios.defaults.withCredentials = true;
Log in
_getUserData () {
let data2 = qs.stringify(this.loginInfo)
this.$axios.post("/apis/jxue/a/login",data2,{
headers:{
"Content-Type":"application/x-www-form-urlencoded"
},
withCredentials:true
})
.then((res)=>{
console.log(res);
})
}
this is the result of the request
Cookie
because the cookie returned to me by the backend contains confirmation login information such as ID. But I can"t get it now.