BlogPlaygroundOne

useDate API


Exposed
(date: unknown, amount: number) => unknown
(date: unknown, amount: number) => unknown
(date: unknown, amount: number) => unknown
(date: unknown, amount: number) => unknown
(date: unknown, amount: number) => unknown
(value: any) => unknown
(date: unknown) => unknown
(date: unknown) => unknown
(date: unknown) => unknown
(date: unknown) => unknown
(date: unknown, formatString: string) => string
(date: unknown) => number
(date: unknown, comparing: unknown, unit: string) => number
(date: unknown) => number
(date: unknown) => number
(date: unknown) => number
(date: unknown) => unknown
(date: unknown) => unknown
( date: unknown, firstDayOfWeek: string | number, firstDayOfYear: string | number, ) => number
(date: unknown, firstDayOfWeek: string | number) => unknown[][]
( firstDayOfWeek: string | number, weekdayFormat: 'long' | 'short' | 'narrow', ) => string[]
(date: unknown) => number
(date: unknown, comparing: unknown) => boolean
(date: unknown, comparing: unknown) => boolean
(date: unknown, comparing: unknown) => boolean
(date: unknown, comparing: unknown) => boolean
(date: unknown, comparing: unknown) => boolean
(date: unknown, comparing: unknown) => boolean
(date: unknown, comparing: unknown) => boolean
(date: any) => boolean
(date: unknown, range: [unknown, unknown]) => boolean
any
(date: string) => unknown
(date: unknown, day: number) => unknown
(date: unknown, hours: number) => unknown
(date: unknown, minutes: number) => unknown
(date: unknown, month: number) => unknown
(date: unknown, year: number) => unknown
(date: unknown) => unknown
(date: unknown) => unknown
(date: unknown, firstDayOfWeek: string | number) => unknown
(date: unknown) => unknown
(date: unknown) => string
(value: unknown) => Date

Adds the specified number of days to the date.

Adds the specified number of hours to the date.

Adds the specified number of minutes to the date.

Adds the specified number of months to the date.

Adds the specified number of weeks to the date.

Takes any value and returns a date object.

Returns the last second of the day.

Returns the last day of the month.

Returns the last day of the week.

Returns the last day of the year.

Takes a date object and returns it in a specified format.

Returns the day of the month of the date.

Returns the difference between two dates in the specified unit.

Returns the hours of the day of the date.

Returns the minutes of the hour of the date.

Returns the month of the date.

Returns the next month of the date.

Returns the previous month of the date.

Returns the week of the year of the date.

Returns an array of the days of the week of the date.

Returns an array of the names of the days of the week.

Returns the year of the date.

Returns true if the first date is after the second date.

Returns true if the first date is after the second date.

Returns true if the first date is before the second date.

Returns true if the two dates are equal.

Returns true if the two dates are the same day.

Returns true if the two dates are the same month.

Returns true if the two dates are the same year.

Returns true if the date is valid.

Returns true if the first date is within the range of the second and third dates.

Returns the current locale being used.

Parses a date string in ISO format.

Sets the day of the date.

Sets the hours of the date.

Sets the minutes of the date.

Sets the month of the date.

Sets the year of the date.

Returns the first second of the day.

Returns first day of the month.

Returns the first day of the week.

Returns the first day of the year.

Converts date value to a ISO Date Object.

Converts date value to a JS Date Object.