UNPKG

@burglekitt/gmt

Version:

Temporal-based date and time utilities with timezone support and polyfill integration

14 lines (13 loc) 431 B
/** * Return the year for a given ISO 8601 zoned datetime string. * * - Returns string for year. * - Returns "" for invalid input. * * @param value ISO zoned datetime string * @returns Year as string or "" on invalid input * * @example parseYearFromZoned("2024-03-15T14:30:45.123+00:00[UTC]") // "2024" * @example parseYearFromZoned("invalid") // "" */ export declare function parseYearFromZoned(value: string): string;