Skip to content

Conversation

@Rac75116
Copy link

Fixes #558

This PR adds a new option, removeOptionalIfDefaultExists, which allows the code generator to omit the optional modifier for properties that have a default value in the JSON Schema. The enhancement includes updates to the CLI, documentation, and core parsing logic, and is covered by new end-to-end tests.

@calleli
Copy link

calleli commented Oct 27, 2025

Perfect timing!
I realized this morning that I was looking for this functionality :)

Would love to have this in place!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove optional flag in case of default in schema.

2 participants