Data and formatting
Validate numbers and strings, clone or freeze values, format dates and durations, and convert identifier styles.

Mazey provides focused helpers for URLs, dates, validation, objects, DOM operations, browser storage, resource loading, events, browser detection, and web performance. Import the functions you need from the package root.
npm install mazey Mazey keeps reusable functions available through a single package entry while documenting browser-only behavior and Node.js-compatible utilities separately.
Validate numbers and strings, clone or freeze values, format dates and durations, and convert identifier styles.
Work with URLs, DOM classes and styles, storage, cookies, resource loading, browser information, and custom events.
Rollup publishes CommonJS, ESM, browser IIFE, and TypeScript declaration output while the website remains a separate build-time concern.
Install from npm for module projects, or use the browser bundle from a CDN.
Published declarations are included, so a separate types package is not required.
npm install mazeyLoad the latest published browser bundle without updating the URL for each release.
<script src="https://cdn.jsdelivr.net/npm/mazey@latest/lib/mazey.min.js"></script>
<script>
const value = mazey.formatDurationFromMs(90000);
</script>Choose utilities only when their behavior and browser requirements match your project. Browser-only functions should stay behind browser runtime boundaries.
Read the complete typed API documentationimport {
convertCamelToKebab,
formatDurationFromMs,
isValidEmail,
} from "mazey";
formatDurationFromMs(90000); // "1.5 minutes"
convertCamelToKebab("helloWorld"); // "hello-world"
isValidEmail("dev@example.com"); // trueThe playground exercises the same package-root utilities used by consumers and reports invalid input without hiding its explanatory content behind JavaScript.
Supporting browsers may offer an app installation prompt. The installed experience includes the website, playground, and API documentation; it does not alter the npm package or grant additional browser capabilities.