0.1.1 • Published 7 years ago

@rilix/ajv-keywords v0.1.1

Weekly downloads
-
License
MIT
Repository
-
Last release
7 years ago

@rilix/ajv-keywords

Build Status Test Coverage Code Climate Issue Count

This lid adds some keywords to ajv, mainly to facilitate our translations.

How to user:

import Ajv from 'ajv';
import rilixAjvKeywords from '@rilix/ajv-keywords';

const ajv = new Ajv();
rilixAjvKeywords(ajv);

ajv.validate({ email: true }, 'example@example.com'); // true
ajv.validate({ email: true }, 'example'); // false

For more usage examples please refer to the spec folder or open an issue with a question.

0.1.1

7 years ago

0.1.0

7 years ago