Skip to content

Clarification for the use of eachWeekOfInterval #2381

Answered by fturmel
sfabriece asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @sfabriece,

The way I understand it, by using { weekStartsOn: 4 } you are defining Thursdays as the first day of the week. The default value for this option is 0 (Sunday).

March 29th is a Monday, and is part of the week that starts on Thursday March 25th.
April 4th is a Sunday, and is part of the week that starts on Thursday April 1st.

Hope that explains it!

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by tan75
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants