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 am switching from AJV/JSON Schema files to TypeBox via a custom middleware around express. The Middleware also generates OpenAPI definitions for every route it manages. Ref: https://github.com/openaddresses/batch-schema
As part of the generation it would use the description field from the JSON Schema to populate human readable parameters/queries/bodies in the OpenAPI definition. Now that I've switched to using typebox in place of the schema it's been working perfectly expcept for the loss of the ability to set the description field on typebox defined types.
I've searched the code and readme and I'm not seeing an ability to do something like below.
Type.Object{username: Type.String({"description": "The username of the user")},{"description": "An object containing user information"})
If this doesn't exist would it be something the community would find useful and if it does would folks be able to point me in the right direction of a code sample.
Context
I am switching from AJV/JSON Schema files to TypeBox via a custom middleware around express. The Middleware also generates OpenAPI definitions for every route it manages. Ref: https://github.com/openaddresses/batch-schema
As part of the generation it would use the
description
field from the JSON Schema to populate human readable parameters/queries/bodies in the OpenAPI definition. Now that I've switched to using typebox in place of the schema it's been working perfectly expcept for the loss of the ability to set thedescription
field on typebox defined types.I've searched the code and readme and I'm not seeing an ability to do something like below.
Would generate
If this doesn't exist would it be something the community would find useful and if it does would folks be able to point me in the right direction of a code sample.
cc @sinclairzx81
The text was updated successfully, but these errors were encountered: