AddJsonFormatters Method
Definition
- Namespace
- Cuemon.Extensions.AspNetCore.Mvc.Formatters.Text.Json
- Assemblies
- Cuemon.Extensions.AspNetCore.Mvc.Formatters.Text.Json.dll
AddJsonFormatters(IMvcBuilder, Action<JsonFormatterOptions>)
Adds the JSON serializer formatters to MVC.
public static IMvcBuilder AddJsonFormatters(this IMvcBuilder builder, Action<JsonFormatterOptions> setup = null)
Parameters
builderIMvcBuilderThe IMvcBuilder.
setupAction<JsonFormatterOptions>The JsonFormatterOptions which may be configured.
Returns
- IMvcBuilder
A reference to
builderafter the operation has completed.
Exceptions
- ArgumentNullException
buildercannot be null -or-setupcannot be null.