Built and signed on GitHub ActionsBuilt and signed on GitHub Actions
Built and signed on GitHub Actions
⏳ Fantastic cron parser and constructor.
This package works with Cloudflare Workers, Node.js, Deno, Bun, Browsers
JSR Score
100%
Published
2 months ago (0.3.3)
import { join, optional } from "jsr:@coven/expression@^0.3.3"; /** * Regular expression to match field with an optional `0` to it's left. * * @example * ```typescript * paddedRegExp(5); // "0?5" * ``` * @param value Value to pad. * @returns RegExp to match value with padded `0`. */ export const paddedRegExp = <Value extends number | string>( value: Value, ): `0?${Value}` => join(optional(0), value);