Advertisement
Guest User

Untitled

a guest
Sep 15th, 2019
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. // Services
  2. services.AddCors(options =>
  3. {
  4. // this defines a CORS policy called "default"
  5. options.AddPolicy("default", policy =>
  6. {
  7. policy.AllowAnyOrigin()
  8. .AllowAnyHeader()
  9. .AllowAnyMethod();
  10. });
  11. });
  12.  
  13. // Configure()
  14. app.UseCors("default");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement