📜  react 不会自动发送 cookie - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:03:16.983000             🧑  作者: Mango

代码示例1
fetch and axios indeed do not send credentials automatically with the request,
you will have to specify it by setting the "withCredentials" option to true:

axios.get(`api.com/api`, { withCredentials: true })
  .then((res) => {
    // code
  })