type DateUnits = 'milliseconds' | 'seconds' | 'minutes' | 'hours' | 'days' | 'months' | 'years'; /** * Performs date difference d1 - d2 in the specified unit. * @param d1 Date * @param d2 Date * @param unit string * @returns number */ export declare const dateDiff: (d1: any, d2: any, unit?: 'milliseconds' | 'seconds' | 'minutes' | 'hours' | 'days') => any; /** * Returns -1 is d1 < d2, and 1 otherwise. Ideal for sorting by dates * @param d1 Date * @param d2 Date * @returns number */ export declare const compareDates: (d1: any, d2: any) => 1 | -1; /** * Returns a new date with the specified amount of units added * @param date The target date * @param amount The amount to add * @param unit The unit of the determined amount to add * @returns */ export declare const dateAdd: (date: any, amount: number, unit: DateUnits) => number; /** * Returns a new date with the specified amount of units subtracted * @param date The target date * @param amount The amount to subtract * @param unit The unit of the determined amount to subtract * @returns */ export declare const dateSubtract: (date: any, amount: number, unit: DateUnits) => number; export {}; //# sourceMappingURL=dates.d.ts.map