-
Notifications
You must be signed in to change notification settings - Fork 3k
Description
Currently, week calculations as presented here: https://html.spec.whatwg.org/multipage/infrastructure.html#weeks assume first week is calculated the same way for all locales.
CLDR and ICU have special data item called minDays
and a method called getMinimalDaysInFirstWeek
to make the calendar week calculations match the common patterns for a given locale.
Most userland date/time libraies (like, jquery's globalization and calendar) use that and it seems like a bug that W3C spec doesn't.
[0] https://github.com/unicode-cldr/cldr-core/blob/master/supplemental/weekData.json#L9
[1] http://icu-project.org/apiref/icu4c/classicu_1_1Calendar.html#a8b667a3b107b4269d57fdd58e76f37c1
[2] https://github.com/jquery/globalize/blob/master/src/date/format.js#L123