tc39 / proposal-temporal

Provides standard objects and functions for working with dates and times.
https://tc39.es/proposal-temporal/docs/
Other
3.26k stars 148 forks source link

Polyfill : undefined weekOfYear and yearOfWeek with calendarId = "islamic-civil" #2905

Open GldzzPro opened 2 months ago

GldzzPro commented 2 months ago

Temporal.PlainDate with calendarId = "islamic-civil" always return undefined weekOfYear and yearOfWeek proprieties islamic-civic

ptomato commented 1 month ago

Most JS implementations will get this data from CLDR, which currently doesn't provide it for any Hijri calendar. There is a proposal to add it, which I recommend you follow: https://github.com/khawarizmus/hijri-week-calendar-proposal

khawarizmus commented 1 month ago

Thank you for the mention @ptomato but for a better developer experience and elaborate documentation and long term support I suggest this library. https://github.com/zamanapp/week-dates

khawarizmus commented 1 month ago

Also to follow the progress of this landing on the CLDR check this issue

https://github.com/khawarizmus/hijri-week-calendar/issues/3

I haven't followed up through this yet but I should be starting that process soon.