Open morgante opened 2 years ago
When a property has a default value, it should not be added to the required array.
required
This comes up in classes. For example, this TypeScript
class Test { enabled = true; }
Generates this schema:
"Test": { "additionalProperties": false, "properties": { "enabled": { "default": true, "type": "boolean" }, }, "required": ["enabled"], "type": "object" }
I have the same requirement and expected properties with default values not be required. Any chance, that may be solved?
When a property has a default value, it should not be added to the
required
array.This comes up in classes. For example, this TypeScript
Generates this schema: