I\'m not sure what I\'m missing, but can\'t seem to get my CORS Policy working with .NET Core 3.1 and Angular 8 client-side.
Startup.cs
:
When adding the Cors Service make sure to include .SetIsOriginAllowed((host) => true)
after .WithOrigins("http://localhost:4200")
services.AddCors(options => {
options.AddPolicy("mypolicy",builder => builder
.WithOrigins("http://localhost:4200/")
.SetIsOriginAllowed((host) => true)
.AllowAnyMethod()
.AllowAnyHeader());
});