registration

This commit is contained in:
User
2025-02-02 16:08:03 +03:00
parent 7f6495eb4d
commit 78afbaed71
6334 changed files with 196774 additions and 165754 deletions

View File

@@ -1,4 +1,6 @@
import type {
ContextOptions,
DateArg,
FirstWeekContainsDateOptions,
LocalizedOptions,
WeekOptions,
@@ -9,7 +11,8 @@ import type {
export interface GetWeekYearOptions
extends LocalizedOptions<"options">,
WeekOptions,
FirstWeekContainsDateOptions {}
FirstWeekContainsDateOptions,
ContextOptions<Date> {}
/**
* @name getWeekYear
* @category Week-Numbering Year Helpers
@@ -24,8 +27,6 @@ export interface GetWeekYearOptions
*
* Week numbering: https://en.wikipedia.org/wiki/Week#The_ISO_week_date_system
*
* @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).
*
* @param date - The given date
* @param options - An object with options.
*
@@ -46,7 +47,7 @@ export interface GetWeekYearOptions
* const result = getWeekYear(new Date(2004, 11, 26), { firstWeekContainsDate: 4 })
* //=> 2004
*/
export declare function getWeekYear<DateType extends Date>(
date: DateType | number | string,
export declare function getWeekYear(
date: DateArg<Date> & {},
options?: GetWeekYearOptions,
): number;