UNPKG

@mantine/form

Version:

Mantine form management library

16 lines (15 loc) 474 B
"use client"; //#region packages/@mantine/form/src/validators/is-not-empty-html/is-not-empty-html.ts function removeHtmlTags(input) { return input.replace(/<\/?[^>]+(>|$)/g, ""); } function isNotEmptyHTML(error) { const _error = error || true; return (value) => { if (typeof value === "string") return removeHtmlTags(value).trim().length > 0 ? null : _error; return _error; }; } //#endregion export { isNotEmptyHTML }; //# sourceMappingURL=is-not-empty-html.mjs.map