registration
This commit is contained in:
22
frontend/style/node_modules/date-fns/formatDistanceStrict.d.ts
generated
vendored
22
frontend/style/node_modules/date-fns/formatDistanceStrict.d.ts
generated
vendored
@@ -1,10 +1,16 @@
|
||||
import type { LocalizedOptions, RoundingOptions } from "./types.js";
|
||||
import type {
|
||||
ContextOptions,
|
||||
DateArg,
|
||||
LocalizedOptions,
|
||||
RoundingOptions,
|
||||
} from "./types.js";
|
||||
/**
|
||||
* The {@link formatDistanceStrict} function options.
|
||||
*/
|
||||
export interface FormatDistanceStrictOptions
|
||||
extends LocalizedOptions<"formatDistance">,
|
||||
RoundingOptions {
|
||||
RoundingOptions,
|
||||
ContextOptions<Date> {
|
||||
/** Add "X ago"/"in X" in the locale language */
|
||||
addSuffix?: boolean;
|
||||
/** If specified, will force the unit */
|
||||
@@ -39,10 +45,8 @@ export type FormatDistanceStrictUnit =
|
||||
* | 1 ... 11 months | [1..11] months |
|
||||
* | 1 ... N years | [1..N] years |
|
||||
*
|
||||
* @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 date
|
||||
* @param baseDate - The date to compare with
|
||||
* @param laterDate - The date
|
||||
* @param earlierDate - The date to compare with
|
||||
* @param options - An object with options
|
||||
*
|
||||
* @returns The distance in words
|
||||
@@ -99,8 +103,8 @@ export type FormatDistanceStrictUnit =
|
||||
* })
|
||||
* //=> '1 jaro'
|
||||
*/
|
||||
export declare function formatDistanceStrict<DateType extends Date>(
|
||||
date: DateType | number | string,
|
||||
baseDate: DateType | number | string,
|
||||
export declare function formatDistanceStrict(
|
||||
laterDate: DateArg<Date> & {},
|
||||
earlierDate: DateArg<Date> & {},
|
||||
options?: FormatDistanceStrictOptions,
|
||||
): string;
|
||||
|
||||
Reference in New Issue
Block a user