-
-
Notifications
You must be signed in to change notification settings - Fork 7.3k
Open
Description
Currently I have a custom type declared as such:
"typeMappings": {
"string+my-custom-value-type": "MyCustomValueType"
}MyCustomValueType is a struct (e.g. value type).
In non-nullable context the type is generated as expected:
"exampleProperty": {
"type": "string",
"format": "my-custom-value-type"
}public MyCustomValueType ExampleProperty { get; set; }But whenever I define a property as nullable the generated property is missing the explicit ? (nullable) suffix required for value types.
OpenAPI spec:
"exampleProperty": {
"type": "string",
"format": "my-custom-value-type",
"nullable": true
}public MyCustomValueType ExampleProperty { get; set; }Expected:
public MyCustomValueType? ExampleProperty { get; set; }Is there a way to tell the (aspnetcore) generator to treat a custom type as a value type?
Metadata
Metadata
Assignees
Labels
No labels