I have a ASP.NET 5 Web API (Well, MVC now anyway) back-end which I am consuming in with the axios library in my JS app.
My CORS config in MVC is the following:
For me helps this:
services.AddCors(options =>{ options.AddPolicy(AllowAllCorsPolicy, builder =>{ builder .SetIsOriginAllowed(x =>_ = true) .AllowAnyMethod() .AllowAnyHeader() .AllowCredentials(); }); });
Taken from .