1.0.1 • Published 5 years ago
checkok-max v1.0.1
checkok-max
Installation
yarn add checkok checkok-max
Usage
import { check } from 'checkok'
import max from 'checkok-max'
// max length in string
const result = check('foobar').pipe(max(10, 'some, msg'))
console.log(result) // { ok: true }
// max in number
const result = check(5).pipe(max(10, 'some, msg'))
console.log(result) // { ok: true }