1.0.3 • Published 4 years ago

enapso-validator v1.0.3

Weekly downloads
4
License
Apache-2.0
Repository
github
Last release
4 years ago

ENAPSOvalidator - Ultrafast Multipurpose Object Validation and Transformation

ENAPSO Validator is about 10x quicker than the joi validation library.

Installation

npm i @innotrade/enapso-validator --save

Usage

The architecture of the ENAPSO validation module is as simple as powerful. Validations are performed against a schema, which consists of one or multiple rule chains, each of consists of one or multiple rules. The rules are simple functions that compare a given value of an inbound object against the reference values in the schema.

Schema

RuleChain

Rule

Field Validation

Custom Rules

Object Validation

Options

For performance reasons, per default rule chains are terminated once a violation of a rule is detected and a schema validation is terminated once a violation in a rule chain is detected.

Transformation

1.0.2

4 years ago

1.0.3

4 years ago

1.0.1

4 years ago