Closed juanmesa-jt closed 3 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 98.98%. Comparing base (
15584b9
) to head (4106fe3
). Report is 1 commits behind head on main.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
I'd be happy to merge this if you can also update the docs
Docs updated.
This commit introduces a new feature that allows specifying enum values for array items in the JSON schema using the
itemEnum
annotation.Changes:
Schema
struct inschema.go
to include a newItemsEnum
field to store the enum values for array items.processComment
function inschema.go
to handle theitem_enum
annotation and assign the enum values to theEnum
field of theItems
schema.With this feature, users can now define enum values for array items in their YAML files using the
itemEnum
annotation, and the generated JSON schema will include the enum values within theitems
section.Example:
Generated JSON for this value will look like