[GH-ISSUE #503] Use js Intl api instead of date-fns format #6196

Open
opened 2026-04-20 16:47:51 -05:00 by GiteaMirror · 0 comments
Owner

Originally created by @vikunja-bot on GitHub (Apr 1, 2025).
Original GitHub issue: https://github.com/go-vikunja/vikunja/issues/503

Original issue by dpschen on 2021-12-11T12:57:23.000Z

The ECMAScript Internationalization API can replace a lot of parts maybe even everything of date-fns and has good support.

Original issue on Gitea


@kolaente commented on 2021-12-11T13:03:09.000Z:

Can it do things like "two hours ago"?


dpschen commented on 2021-12-11T13:05:58.000Z:

Yes with RelativeTimeFormat. It's a really good api! They basically try to undo the fuckup they did with the normal js date =)


@kolaente commented on 2021-12-11T13:07:02.000Z:

Ohhh right, I remember having read something about this. Finally no more months starting at 0!

Looks great!

Originally created by @vikunja-bot on GitHub (Apr 1, 2025). Original GitHub issue: https://github.com/go-vikunja/vikunja/issues/503 _Original issue by dpschen on 2021-12-11T12:57:23.000Z_ The [ECMAScript Internationalization API](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl) can replace a lot of parts maybe even everything of date-fns and has good support. [Original issue on Gitea](https://kolaente.dev/vikunja/vikunja/issues/1884) --- _**@kolaente** commented on 2021-12-11T13:03:09.000Z_: Can it do things like "two hours ago"? --- _**dpschen** commented on 2021-12-11T13:05:58.000Z_: Yes with [RelativeTimeFormat](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/RelativeTimeFormat/RelativeTimeFormat). It's a really good api! They basically try to undo the fuckup they did with the normal js date =) --- _**@kolaente** commented on 2021-12-11T13:07:02.000Z_: Ohhh right, I remember having read something about this. Finally no more months starting at 0! Looks great!
GiteaMirror added the area/frontendarea/internal-codearea/i18n labels 2026-04-20 16:47:51 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/vikunja#6196