Skip to content

v0.8.1

Choose a tag to compare

@GREsau GREsau released this 23 Mar 20:20
· 352 commits to master since this release

Added:

  • SchemaGenerator::definitions_mut() which returns a mutable reference to the generator's schema definitions
  • Implement JsonSchema for slices

Changed:

  • Minimum supported rust version is now 1.37.0
  • Deriving JsonSchema on enums now sets additionalProperties to false on generated schemas wherever serde doesn't accept unknown properties. This includes non-unit variants of externally tagged enums, and struct-style variants of all enums that have the deny_unknown_fields attribute.
  • Schemas for HashSet and BTreeSet now have uniqueItems set to true (#64)

Fixed

  • Fix use of #[serde(transparent)] in combination with #[schemars(with = ...)] (#67)
  • Fix clippy field_reassign_with_default warning in schemars_derive generated code in rust <1.51 (#65)
  • Prevent stack overflow when using inline_subschemas with recursive types