UNPKG

sd-formik-validators

Version:
12 lines (11 loc) 405 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.composeValidators = function () { var validators = []; for (var _i = 0; _i < arguments.length; _i++) { validators[_i] = arguments[_i]; } return function (value) { return validators.reduce(function (error, validator) { return error || validator(value); }, undefined); }; };