0.0.36 • Published 5 years ago

@cuser/validator v0.0.36

Weekly downloads
1
License
MIT
Repository
github
Last release
5 years ago

Status

codecov npm npm-downloads

@cuser/validator

Index

Classes

Functions

Functions

createValidator

ConstcreateValidator(schema: any): validate

Defined in validator.js:34

Creates a validator which raise a ValidationError when the object doesn't fit the schema

Parameters:

NameTypeDescription
schemaany

Returns: validate

Class: ValidationError

Validator error class with nested errors

Hierarchy

  • Error

    ValidationError

Index

Constructors

Constructors

constructor

+ new ValidationError(message: any, validator: ValidateFunction, value: any): ValidationError

Defined in validator.js:15

Parameters:

NameType
messageany
validatorValidateFunction
valueany

Returns: ValidationError

0.0.30

5 years ago

0.0.31

5 years ago

0.0.32

5 years ago

0.0.33

5 years ago

0.0.34

5 years ago

0.0.35

5 years ago

0.0.36

5 years ago

0.0.29

5 years ago

0.0.27

5 years ago

0.0.25

5 years ago

0.0.26

5 years ago

0.0.18

5 years ago

0.0.16

5 years ago

0.0.17

5 years ago

0.0.12

5 years ago

0.0.8

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago