Skip to content
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

fix: weekday check function for other locales #222

Merged
merged 1 commit into from
Aug 13, 2024

Conversation

cheeselemon
Copy link
Contributor

@cheeselemon cheeselemon commented Dec 7, 2023

Fixing issue #150 , #221

Screenshot 2023-12-07 at 6 57 08 PM

Problem:

  • Calendar doesn't show previous month, all months start with 1.

Reason:

  • This is due to getNumberOfDay being stuck at number = 0, when delcaring dayjs.locale() other than "en" globally outside library.

The Fix:

  • Instead of using hard-coded weekday string array ["Sunday", ... "Saturday"], a function is created to specifically use previously set locales.

@cheeselemon cheeselemon changed the title #150 Fix weekday check function for other locales #221 Fix weekday check function for other locales Dec 7, 2023
@Maycon-Santos
Copy link

Merge please! 🥲

@cheeselemon cheeselemon changed the title #221 Fix weekday check function for other locales fix: weekday check function for other locales Apr 4, 2024
@onesine
Copy link
Owner

onesine commented Aug 13, 2024

Hello @cheeselemon 👋.
Sorry for the late reply.
Thanks for the contribution.

@onesine onesine merged commit a1a3b52 into onesine:master Aug 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants