UNPKG

simple-body-validator

Version:

This package is inspired by Laravel validation, and aims to make body validation easier for Javascript developers

10 lines (9 loc) 484 B
import RequiredIf from './rules/requiredIf'; import In from './rules/in'; import NotIn from './rules/notIn'; import Regex from './rules/regex'; export declare function requiredIf(callback: boolean | CallableFunction): RequiredIf; export declare function ruleIn(values: (string | number)[]): In; export declare function ruleNotIn(values: (string | number)[]): NotIn; export declare function regex(value: RegExp): Regex; export declare function notRegex(value: RegExp): Regex;