Skip to content

v1.0.0-alpha.15

Pre-release
Pre-release
Compare
Choose a tag to compare
@GREsau GREsau released this 05 Sep 12:04
· 8 commits to master since this release

Added

  • SchemaSettings now has a contract field which determines whether the generated schemas describe how types are serialized or deserialized. By default, this is set to Deserialize, as this more closely matches the behaviour of previous versions - you can change this to Serialize to instead generate schemas describing the type's serialization behaviour (#48 / #335)

Changed

  • Schemas generated for enums with no variants will now generate false (or equivalently {"not":{}}), instead of {"enum":[]}. This is so generated schemas no longer violate the JSON Schema spec's recommendation that a schema's enum array "SHOULD have at least one element".