Loomio

Format of the date is different from what we use

S
Strajk Public Seen by 37

Currently it appears as day, month, day of the month and an hour.
Is there an option to change it globally for polish language. If possible, the best would be:

"czw. godz. 23:00, 31 grudnia 2020" or if not possible to add year:

"czw. godz. 23:00, 31 grudnia"

In polish language we do not use shortcuts for months and use "godz." shortcut before giving an hour/time.

RG

Rob Guthrie Sun 20 Dec 2020

It is possible.

We use date-fns to format dates. It has good localization support. What you're seeing is a date passed into the format function.

We use the following date formats:

  • this year approximate: "MMM d"

  • another year approximate: "yyyy-MM-dd"

  • this year exact: 'EEE MMM d HH:mm'

  • another year exact: 'yyyy EEE MMM d HH:mm'

These are explained on this page:

https://date-fns.org/v2.16.1/docs/format

Do you think you could supply formats for polish? I will add support for per language date formats

RG

Rob Guthrie Sun 20 Dec 2020

@Weronika would it work if we just used 2020-12-21 format?

S

Strajk Sun 20 Dec 2020

So interesting! 2020-12-21 is yyyy-MM-dd yes? It would work just perfectly.

RG

Rob Guthrie Mon 21 Dec 2020

Ok I've updated our date formats based on this conversation. It will be live in 5 minutes from now.

S

Strajk Mon 21 Dec 2020

Thank you.