Skip to content

Latest commit

 

History

History
113 lines (94 loc) · 3.5 KB

CHANGELOG.md

File metadata and controls

113 lines (94 loc) · 3.5 KB

0.6.16 (2019-03-01)

Changes

  • fix typescript definitions.

0.6.15 (2019-02-13)

Changes

  • fix uuid rule. #60
  • fix typescript definitions. #59

0.6.14 (2019-02-07)

Changes


0.6.13 (2019-01-22)

Changes

  • add error message for url rule.
  • add numeric attribute to string rule.
  • add alpha, alphanum & alphadash attributes to string rule.
  • add index.d.ts file.
  • fix multiple validator with different messages issue.

0.6.12 (2018-12-04)

Changes

  • support recursive schemas by @andersnm
  • fix irregular object property names

0.6.11 (2018-10-25)

Changes


0.6.10 (2018-06-25)

Changes

  • fix #27 - multiple optional validators

0.6.9 (2018-06-07)

Changes

  • fix #25 - multiple optional validators
  • Add new enum rule
        { type: "enum", values: ["male", "female"] }

0.6.7 (2018-05-29)

Changes

  • supports multiple object validators #22 by @mauricedoepke
    const schema = {
        list: [
            { 
                type: "object",
                props: {
                    name: {type: "string"},
                    age: {type: "number"},
                } 
            },
            { 
                type: "object",
                props: {
                    country: {type: "string"},
                    code: {type: "string"},
                } 
            }
        ]
    };

0.6.6 (2018-04-04)

Access to the original object in custom validator #5

const schema = {
    email: { 
        type: "custom", 
        check(value, schema, stack, obj) {
            return obj.username || obj.email ? null : this.makeError(...);
        }
    }
};