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

First day of the Month Issue #44

Closed
wilcolinadev opened this issue May 23, 2024 · 9 comments · Fixed by #45
Closed

First day of the Month Issue #44

wilcolinadev opened this issue May 23, 2024 · 9 comments · Fixed by #45

Comments

@wilcolinadev
Copy link

Hey there!

Just happened to notice on one of my projects that, the start of the week is not matching as expected, I thought it probably was a configuration issue on my site, however, I noticed the same problem in the official documentation example.

For example, June, 1st 2024 should be a Saturday while the Calendar is displaying that day as a Sunday.

Let me know if it could just be something related to my time, or if it might be an issue with the utils or even better just an issue on my end.

Thank you for taking a look!

Reference Screenshots below

Screenshot 2024-05-22 at 8 43 06 PM
Screenshot 2024-05-22 at 8 43 21 PM

@WickyNilliams
Copy link
Owner

Oh that's weird. Seems related to #18

Did you change anything in the above screenshot to show Tuesday as first day of the week? Seems like an off by one error somehow.

May I ask what timezone you are in?

@wilcolinadev
Copy link
Author

No, I did not change anything in the screenshots. It seems to be fine just now, but I have already seen it happen twice during the past two evenings, which is definitely making me think that it could be a timezone issue.

I am located in Central Daylight Time GMT-5

@WickyNilliams
Copy link
Owner

Thanks for the info. Yeah must be related to timezone. Can you give some info on browser (+ version) and OS please?

@wilcolinadev
Copy link
Author

You got it,

Chrome Version for the Browser
Version 125.0.6422.76 (Official Build) (arm64)
Mac OS Sonoma

The issue was also consistent across iPads and IPhone, with the latest OS versions using chrome

@WickyNilliams
Copy link
Owner

WickyNilliams commented May 23, 2024

I noticed there were some places I wasn't using getUTC*/setUTC* methods on Date. I have fixed those up now, and released as 0.6.1.

I'm hoping that fixes things for you. Can you check (around the same time you observed the bug?) and report back please. You might want to clear you browser cache to be sure you're getting the latest version from the docs

@wilcolinadev
Copy link
Author

Hey, thanks a lot for checking on that, I will keep an eye on it today, and if I see something weird I will let you know.

@WickyNilliams
Copy link
Owner

Appreciate it! I'll reopen this issue for now pending your feedback

@WickyNilliams WickyNilliams reopened this May 24, 2024
@wilcolinadev
Copy link
Author

wilcolinadev commented May 25, 2024

I looked it up over the past two days and I did not see the bug, so it looks like that was the issue, thanks a lot for looking into it so quickly, take care!

@WickyNilliams
Copy link
Owner

Great! Glad to hear. Hopefully that's the last of the bugs related to this. It really is an uphill battle to prevent JS printing dates in user's timezone

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 a pull request may close this issue.

2 participants