Releases: mojotech/json-type-validation
Releases · mojotech/json-type-validation
v3.1.0
Minor changes:
Upgrade Notes:
The library now uses TS 3.1 internally, and a number of instances of any have been replaced with the newer unknown type. Projects using < [email protected] will need a polyfill for the unknown type, such as unknown-ts.
v3.0.0
Major changes:
- Remove exported
decoderErrorStringfunction f21e684 - Do not throw an Error object from
Result.withException77ad1c3
Minor changes:
- Add
intersectiondecoder 678fada - The
array()decoder with no arguments validatesany[]d4326b5 - The
object()decoder with no arguments validates dictionaries withanyvalues b989a86 - Add
wheredecoder method for adding non-type constraints on a decoder fc14fe0
Patch changes:
- Fix missing 'lodash' production dependency 1026a4d
v2.0.0
Major changes:
- Remove
constantTrue,constantFalse,constantNullfunctions - Functions
constant(true)andconstant(false)always have typeDecoder<true>andDecoder<false>respectively.
Minor changes:
- Improve error messages for
object,valueAt, andoneOfdecoders. - Simplify error messages that have the form "expected X, got Y"
constantdecoder can match constant arrays and objects
Patch changes:
- Fix typos in readme
- Remove unused dependencies