startOfWeek
Return the start of a week for the given date.
// The start of a week for 2 October 2021 09:50:01: const result = startOfWeek(new Date(2021, 10, 2, 09, 50, 1)) //=> Sep 26 2021 00:00:00
the original date
the start of a month
Generated using TypeDoc
startOfWeek
Return the start of a week for the given date.
Return the start of a week for the given date.
// The start of a week for 2 October 2021 09:50:01: const result = startOfWeek(new Date(2021, 10, 2, 09, 50, 1)) //=> Sep 26 2021 00:00:00