Strickland
Search…
Validation
Strickland's default export is a validate function that accepts a validator function and the value to validate against the validator; it returns the validation result.
1
import validate from 'strickland';
2
3
function letterA(value) {
4
return (value === 'A');
5
}
6
7
const result = validate(letterA, 'B');
Copied!
Last modified 1yr ago
Copy link