Skip to content

v0.10.0

Compare
Choose a tag to compare
@jprochazk jprochazk released this 01 Apr 21:06
· 243 commits to main since this release

Breaking changes

  • Errors now has a new Nested variant.
  • Display now uses the output of flatten instead of only recursively printing errors.

Fixes

  • Result aliases declared in the same scope as the output of the Validate derive macro will no longer cause conflicts. (#24)

New features

  • dive now works together with other rules:
#[derive(garde::Validate)]
struct Item {
  #[garde(ascii)]
  field: String,
}

#[derive(garde::Validate)]
struct Example {
  #[garde(length(min=1), dive)]
  items: Vec<Item>,
}
  • each field may now have any number of custom rules:
#[derive(garde::Validate)]
struct Example {
  #[garde(custom(a), custom(b), custom(c))]
  items: String,
}

What's Changed

Full Changelog: https://github.com/jprochazk/garde/compare/v0.9.2..v0.10.0