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

render dates localized for the user #2

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

paulirish
Copy link
Contributor

because UTC is hard for my California brain.

screenshot:
image


also switch the readme headers.. (they're swapped :)

@HSZemi
Copy link
Member

HSZemi commented May 16, 2024

Where backend and frontend are wholly depends on which side you're looking from, right? 😬

While the timestamps returned by the API seem to indeed be UTC timestamps, I am noticing that timezone identifiers are missing. If you could add those, I would even be willing to allow the display of non rfc3339 compliant timestamps, depending on the locale 😳

@paulirish
Copy link
Contributor Author

:)

Well, in this PR, the resulting date is localized to the users timezone. Do you still want the 2-3 letter identifiers afterwards anyway?

@HSZemi
Copy link
Member

HSZemi commented May 24, 2024

Do you still want the 2-3 letter identifiers afterwards anyway?

Yes, please. You cannot tell just by looking if it's just the timestamp formatted in the user's locale or actually converted to the user's local timezone as well. And I would like that to be clear immediately.

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.

2 participants