runtypes

Runtime validation for static types

MIT License

Stars
2.5K
Committers
43

Bot releases are hidden (Show)

runtypes -

Published by pelotom over 4 years ago

  • Add key to throw ValidationError in decorator (#117)
  • Add failed key to error message (#121)
runtypes -

Published by pelotom about 5 years ago

Fixes issue with circularity detection in show() (#108)

runtypes -

Published by pelotom about 5 years ago

Improve performance by using pure guard function as the primitive type checking operation rather than exceptions (#99)

runtypes -

Published by pelotom about 5 years ago

Remove reflect-metadata dependency and simplify @checked decorator code (#101)

runtypes -

Published by pelotom over 5 years ago

Big thanks to @justingrant for the major contributions in this release:

  • Enable Constraint to have a custom name and/or a custom static type (#78)
    • Convenience method withGuard for producing runtypes from type guards
    • BREAKING CHANGE: Constraint's args parameter moved to within options parameter (this likely does not affect many users)
  • Adds TypeScript 3.5 compatibility
runtypes -

Published by pelotom over 5 years ago

  • Add isReadonly flag to Array and Record runtypes (#80)
  • Deprecate the Void runtype (#82)
runtypes -

Published by pelotom almost 6 years ago

Make ValidationError public (#59)

runtypes -

Published by pelotom almost 6 years ago

Fix bug with @checked (#72)

runtypes -

Published by pelotom almost 6 years ago

Replace Always with Unknown

runtypes -

Published by pelotom almost 6 years ago

Add @checked decorator (#71)

runtypes -

Published by pelotom about 6 years ago

Treat missing fields as undefined (#61)

runtypes -

Published by pelotom over 6 years ago

  • Added Symbol runtype (#53)
  • Added support for branded types (#55)
runtypes -

Published by pelotom over 6 years ago

More descriptive error messages (https://github.com/pelotom/runtypes/pull/51)

runtypes -

Published by pelotom over 6 years ago

Fix compilation under TypeScript 2.8

runtypes -

Published by pelotom over 6 years ago

runtypes -

Published by pelotom over 6 years ago

runtypes -

Published by pelotom over 6 years ago

runtypes -

Published by pelotom over 6 years ago

Add top-level match function, change match API to use varargs instead of tuples.

runtypes -

Published by pelotom over 6 years ago

Updated documentation.

runtypes -

Published by pelotom over 6 years ago

This release adds match method to Union for doing case analysis across variants.

Badges
Extracted from project README
License Coverage Status