endOfWeekFixed
Calendar
stable
Returns the last day of the week starting on a given weekday index (0 = Sunday, 1 = Monday …). Symmetric counterpart to startOfWeekFixed. Used by the calendar's week/day views.
API
Signature
Signature TypeScript complète, extraite du fichier util.
API
Paramètres
Paramètres d'entrée acceptés par cet util.
- daterequisDate
- Any date within the target week.
- firstDayOfWeekrequisnumber
- Weekday index for the first day of the week. 0 = Sunday, 1 = Monday, …, 6 = Saturday.
API
Valeur de retour
La valeur retournée par cet util.
- A new Date at midnight on the last day of the week (startOfWeekFixed + 6 days).
Usage
Exemples
Extraits de code prêts à coller.
Week ending on Saturday (Sunday-first)