Rocky_Mountain_Vending/.pnpm-store/v10/files/16/cef98b7fd4a90d84acd5ad54554151952842db6c62b57307d7648735f0d76590583774d11882c16a1055ff92926b57968907aac3b8c6c91b9e9b19a581e9af
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

46 lines
1.7 KiB
Text

import type { ContextOptions } from "./types.js";
/**
* The {@link parseISO} function options.
*/
export interface ParseISOOptions<DateType extends Date = Date>
extends ContextOptions<DateType> {
/** The additional number of digits in the extended year format */
additionalDigits?: 0 | 1 | 2;
}
/**
* @name parseISO
* @category Common Helpers
* @summary Parse ISO string
*
* @description
* Parse the given string in ISO 8601 format and return an instance of Date.
*
* Function accepts complete ISO 8601 formats as well as partial implementations.
* ISO 8601: http://en.wikipedia.org/wiki/ISO_8601
*
* If the argument isn't a string, the function cannot parse the string or
* the values are invalid, it returns Invalid Date.
*
* @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).
* @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.
*
* @param argument - The value to convert
* @param options - An object with options
*
* @returns The parsed date in the local time zone
*
* @example
* // Convert string '2014-02-11T11:30:30' to date:
* const result = parseISO('2014-02-11T11:30:30')
* //=> Tue Feb 11 2014 11:30:30
*
* @example
* // Convert string '+02014101' to date,
* // if the additional number of digits in the extended year format is 1:
* const result = parseISO('+02014101', { additionalDigits: 1 })
* //=> Fri Apr 11 2014 00:00:00
*/
export declare function parseISO<
DateType extends Date,
ResultDate extends Date = DateType,
>(argument: string, options?: ParseISOOptions<ResultDate>): ResultDate;