1 services.AddMvc(options => 2 { 3 options.UseWtmMvcOptions(); 4 }) 5 .AddJsonOptions(options => { 6 options.UseWtmJsonOptions(); 7 options.JsonSerializerOptions.PropertyNamingPolicy = JsonNamingPolicy.CamelCase; 8 9 })
WTM .NET 5 JSON 返回格式配置-属性名的命名风格
原文:https://www.cnblogs.com/IIXS/p/14747014.html