added cors and added produces json.
This commit is contained in:
@@ -74,6 +74,7 @@ namespace Demo
|
||||
services.AddPoweredSoftGraphQLFluentValidation();
|
||||
|
||||
services.AddSwaggerGen();
|
||||
services.AddCors();
|
||||
}
|
||||
|
||||
private void AddDynamicQueries(IServiceCollection services)
|
||||
@@ -113,6 +114,8 @@ namespace Demo
|
||||
|
||||
app.UseHttpsRedirection();
|
||||
|
||||
app.UseCors(o => o.AllowAnyOrigin().AllowAnyHeader().AllowAnyMethod());
|
||||
|
||||
app.UseRouting();
|
||||
|
||||
app.UseAuthorization();
|
||||
|
||||
Reference in New Issue
Block a user