1 | import type { ContextOptions, DateArg } from "./types.js";
|
2 | /**
|
3 | * The {@link getQuarter} function options.
|
4 | */
|
5 | export interface GetQuarterOptions extends ContextOptions<Date> {}
|
6 | /**
|
7 | * @name getQuarter
|
8 | * @category Quarter Helpers
|
9 | * @summary Get the year quarter of the given date.
|
10 | *
|
11 | * @description
|
12 | * Get the year quarter of the given date.
|
13 | *
|
14 | * @param date - The given date
|
15 | * @param options - An object with options
|
16 | *
|
17 | * @returns The quarter
|
18 | *
|
19 | * @example
|
20 | * // Which quarter is 2 July 2014?
|
21 | * const result = getQuarter(new Date(2014, 6, 2));
|
22 | * //=> 3
|
23 | */
|
24 | export declare function getQuarter(
|
25 | date: DateArg<Date> & {},
|
26 | options?: GetQuarterOptions | undefined,
|
27 | ): number;
|