UNPKG

@northguild/gmt

Version:

Date and time library for JavaScript and TypeScript, built on TC39 Temporal: time zones, DST, business days, ISO 8601 strings in and out. Never throws.

13 lines • 466 B
/** * Return the day (1-31) from a zoned datetime string. * * - Returns zero-padded string for day. * - Returns "" for invalid input. * * @param value ISO zoned datetime string (e.g., "2024-03-15T14:30:45.123+00:00[UTC]") * @returns Day (01-31) or "" on invalid input * * @example parseDayFromZoned("2024-03-15T14:30:45+00:00[UTC]") // "15" * @example parseDayFromZoned("invalid") // "" */ export declare function parseDayFromZoned(value: string): string;