bguard
Version:
**bguard** is a powerful, flexible, and type-safe validation library for TypeScript. It allows developers to define validation schemas for their data structures and ensures that data conforms to the expected types and constraints.
18 lines (13 loc) • 644 B
JavaScript
;Object.defineProperty(exports, "__esModule", {value: true});
var _chunkTJQ5NVL4js = require('./chunk-TJQ5NVL4.js');
// src/asserts/string/minLength.ts
var minLengthErrorMessage = "The received value length is less than expected";
var minLengthErrorKey = "s:minLength";
var minLength = (expected) => (received, ctx) => {
if (received.length < expected) ctx.addIssue(expected, received, minLengthErrorMessage);
};
minLength.key = minLengthErrorKey;
minLength.message = minLengthErrorMessage;
_chunkTJQ5NVL4js.setToDefaultLocale.call(void 0, minLength);
exports.minLength = minLength;
//# sourceMappingURL=chunk-BRFUFNU4.js.map