1. 首页
  2. 数据库
  3. 其它
  4. SpringBoot+vue 在后端给浏览器设置cookie

SpringBoot+vue 在后端给浏览器设置cookie

上传者: 2021-01-17 01:37:46上传 PDF文件 49.92KB 热度 8次
前端的vue项目在这里我使用的是axios插件发请求,首先设置 //表示跨域请求时使用凭证 axios.defaults.withCredentials = true //向后端发送一个请求,用于获取cookie this.axios.get(/setCookies) .then(res =>{ console.log(res) }) .catch(err =>{ console.log(err); }) 后端SpringBoo
下载地址
用户评论