<PackageReference Include="System.Text.Json" Version="10.0.0-preview.2.25163.2" />

JsonSerializableAttribute

Instructs the System.Text.Json source generator to generate source code to help optimize performance when serializing and deserializing instances of the specified type and types in its object graph.

Gets or sets the mode that indicates what the source generator should generate for the type. If the value is Default, then the setting specified on GenerationMode will be used.

public string TypeInfoPropertyName { get; set; }

Gets or sets the name of the property for the generated JsonTypeInfo<T> for the type on the generated, derived JsonSerializerContext type.

Initializes a new instance of JsonSerializableAttribute with the specified type.