Skip to content

Releases: standardschema/javascript

Refactored Structural and Object Type Checking

08 Jun 06:14
Compare
Choose a tag to compare

Fixed

  • Improve structural type checking through inheritance, required and corrected object type check and validation

Transform Type

06 Jun 23:44
Compare
Choose a tag to compare

Added

  • New Types.Transform - for transforming a value during validation

Array `{min,max}Items`

06 Jun 22:38
Compare
Choose a tag to compare

Added

  • Support types.Array.{min,max}Items for validation

References

06 Jun 22:02
Compare
Choose a tag to compare

Added

  • Concept of value references
  • New Types.Omit and Types.Condition

More Graceful Error Handling

03 Jun 17:13
Compare
Choose a tag to compare

Changed

  • When an error occurs in union or every, reject with the first non-validation error (it's likely a code error)
  • Make Intersection and Union inherit from Any (again) - this is useful for uses

Fix Union Compile

03 Jun 06:08
Compare
Choose a tag to compare

Fixed

  • Union types were compiling the old way using compose, use type._compile() instead

Mutate Type

03 Jun 05:38
Compare
Choose a tag to compare

Added

  • Add a Mutate type for temporary mutations during tests

New `Rule` Base Class

03 Jun 05:40
Compare
Choose a tag to compare

Changed

  • Add Rule base class - Any extends Rule now, while some basic rules come included
  • Rewrote the middleware pattern in use - now using next(value) => value where you can forward values and receive back a value - the default next is just the identity function

Correct error message strings

31 May 01:06
Compare
Choose a tag to compare

Fixed

  • Improved the consistency of error message keys
  • Update isType for string sub-types

Remove `ref` option

31 May 00:26
Compare
Choose a tag to compare

Changed

  • Remove ref from AnyOptions