Skip to content

Conversation

Fil
Copy link
Member

@Fil Fil commented Jun 9, 2020

"mardi 9 juin 2020 à 19:09:23" rather than "mardi, le 9 juin 2020, 18:58:57"

locale.format("%c")(new Date()) returns "mardi, le  9 juin 2020, 18:58:57", which is weird.

I can't find a very clear spec, but:
~~~{js}
new Intl.DateTimeFormat('fr-FR', {
  weekday: 'long',
  year: 'numeric',
  month: 'long',
  day: 'numeric',
  hour: 'numeric',
  minute: 'numeric',
  second: 'numeric'
}).format(new Date())
~~~

returns "mardi 9 juin 2020 à 19:09:23", which definitely sounds better.

(This commit returns "mardi  9 juin 2020 à 19:09:23" with an extra space.)
@Fil Fil merged commit e318f1f into master Jul 10, 2020
@Fil Fil deleted the french-locale-fulldate branch July 10, 2020 20:07
Fil added a commit that referenced this pull request Jul 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants