-
-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Datepicker :show-weeks? displays incorrect week number when showing all but Monday w/c #159
Labels
Comments
superstructor
added a commit
that referenced
this issue
Jan 29, 2021
Cause of #159 is that cljs-time (as well as JavaScript, goog.date etc) only have algorithms for calculating the week number of a year for ISO8601 week numbering for which weeks start on Monday. Support for calculating correct week numbers with a custom start of week requires an entirely custom week numbering algorithm.
superstructor
added a commit
that referenced
this issue
Feb 1, 2021
Cause of #159 is that cljs-time (as well as JavaScript, goog.date etc) only have algorithms for calculating the week number of a year for ISO8601 week numbering for which weeks start on Monday. Support for calculating correct week numbers with a custom start of week requires an entirely custom week numbering algorithm.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Datepicker leverages the cljs-time library. When displaying the week number via
:show-weeks?
it uses the 'ww' format here and here In turn it looks like cljs-time uses the IS8601 week numbering which is "Monday" so whenever datepicker is showing anything other then week commencing day Monday, the week numbers are incorrect. This includes the demo app which defaults to Sunday w/c For example see the left datepicker bellow which start W/C Sunday, week number 31 is not correct, should be 30The text was updated successfully, but these errors were encountered: