Request header field token is not allowed by Access-Control-Allow-Headers in preflight response

ant_vue+springboot联调时出现,Request header field token is not allowed by Access-Control-Allow-Headers in preflight response,一直以为是跨域的问题,折腾了半天,原来不是.

需要在后端请求 的headers里面加入token,

我之前哪里写了个token,不知道什么鬼,改为Access-Token正常

猜你喜欢

转载自blog.csdn.net/qq_39310195/article/details/109614829