You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been looking at the CLI options and the only setting related to nullable types is --default-non-nullable which is true by default. I've enabled it just in case and the result is the same.
Sorry, this is my first time using OpenAPI... am I missing something very obvious here?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I'm using NSwag with FastEndpoints in dotnet to generate the OpenAPI spec.
This is the type in the JSON spec:
The properties do not have
nullable: true
and yetopenapi-typescript
marks all these properties as nullable in the TS type:I've been looking at the CLI options and the only setting related to nullable types is
--default-non-nullable
which istrue
by default. I've enabled it just in case and the result is the same.Sorry, this is my first time using OpenAPI... am I missing something very obvious here?
Thanks for any help.
Beta Was this translation helpful? Give feedback.
All reactions