Skip to content

Instantly share code, notes, and snippets.

@berkslv
Created October 20, 2020 13:18
Show Gist options
  • Save berkslv/6ee1bb05732c4eae6202dc177dbd40ab to your computer and use it in GitHub Desktop.
Save berkslv/6ee1bb05732c4eae6202dc177dbd40ab to your computer and use it in GitHub Desktop.
Startup.cs ConfigureServices for CORS
services.AddCors(options =>
{
options.AddPolicy("ClientPermission", policy =>
{
policy.AllowAnyHeader()
.AllowAnyMethod()
.WithOrigins("http://localhost:3000")
.AllowCredentials();
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment