typescript-rest-swagger
typescript-rest-swagger copied to clipboard
Issue with TypeScript union types
It seems that swaggerGen treats anything that is a union type (i.e. string | null
) as just an object. At the very least it would be good to just have it list the first type in the union. But would be best if it listed all available types.
The tsoa
library just introduces support for unions (i.e. |
) and aggregates (i.e. &
):
https://github.com/lukeautry/tsoa