Define Json serialization settings per controller.
Open
affected-very-few
area-mvc
enhancement
feature-mvc-formatting
severity-minor
- Dominant language
- C#
- Stars
- 38.4k
- Forks
- 10.9k
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 290
Description
# Issue Title
Setup Json serialization per controller in the ASPNET Core applicaiton.
# General
Asp net core has a mechanism to define json serialization options per application using:
services
.AddControllers(options => {})
.AddJsonOptions(options => { /* json options */})
;
however there is no way to define json serialization settings per individual controller.
The output json can be controlled by parameter of the Json() method in each action, but there is no way to control how input parameters are deserializing from request body on the action.
Contributor guide
Assessment
This issue has not been assessed yet.