UNPKG

yh-validator

Version:

A lightweight form validation library with modular functions

1 lines 256 B
'use strict';function e(r){if(r==null)throw new TypeError(`Expected a string but received a ${r}`);if(r.constructor.name!=="String")throw new TypeError(`Expected a string but received a ${r.constructor.name}`)}function i(r,n){return e(r),r===n}exports.a=i;