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'm creating a documentation for my API, but when I create a Response t.Object like this: t.Object({ user: t.Object({ id: t.String(), email: t.String(), createdAt: t.Date(), updatedAt: t.Date() }) })
I'm creating a documentation for my API, but when I create a Response t.Object like this:
t.Object({ user: t.Object({ id: t.String(), email: t.String(), createdAt: t.Date(), updatedAt: t.Date() }) })
createdAt and updatedAt is transformed for this on the OpenAPI Document
"createdAt": { "anyOf": [ { "type": "Date" }, { "format": "date", "default": "2024-05-16T23:05:28.064Z", "type": "string" }, { "format": "date-time", "default": "2024-05-16T23:05:28.064Z", "type": "string" } ] }, "updatedAt": { "anyOf": [ { "type": "Date" }, { "format": "date", "default": "2024-05-16T23:05:28.065Z", "type": "string" }, { "format": "date-time", "default": "2024-05-16T23:05:28.065Z", "type": "string" } ] } },
And to work well needs to be like:
"createdAt": { "format": "date", "default": "2024-05-16T23:05:28.065Z", "type": "string" }
Is this an error in my code or a bug on elysia-swagger?
The text was updated successfully, but these errors were encountered: