摘要:services.AddSwaggerGen(c => { c.SwaggerDoc("v1", new OpenApiInfo { Title = "My API", Version = "v1" }); c.AddSecurityDefinition("Bearer", new OpenApiS 阅读全文
posted @ 2020-08-19 14:07 IWing 阅读(54) 评论(0) 推荐(0) 编辑
摘要:services.AddCors(options => { options.AddPolicy("abc", builder => { //App:CorsOrigins in appsettings.json can contain more than one address with split 阅读全文
posted @ 2020-08-19 14:06 IWing 阅读(40) 评论(0) 推荐(0) 编辑
摘要:services.AddControllers().AddJsonOptions(c => { c.JsonSerializerOptions.PropertyNamingPolicy = new NormalPolicy(); }); public class NormalPolicy : Jso 阅读全文
posted @ 2020-08-19 11:05 IWing 阅读(83) 评论(0) 推荐(0) 编辑