Skip to content
This repository was archived by the owner on Apr 14, 2021. It is now read-only.

Wrong date format with locales FR and EN #274

Open
Ghuillaume opened this issue Apr 20, 2017 · 1 comment
Open

Wrong date format with locales FR and EN #274

Ghuillaume opened this issue Apr 20, 2017 · 1 comment

Comments

@Ghuillaume
Copy link

I'm currently using Intl 1.2.5 to set up a locale for PhantomJS on an Angular2 project, and it seems the fr.js is wrong or incomplete.

Using this template :

<span class="hour">{{ time | date:'HH' }}</span>
<span> : </span>
<span class="minutes">{{ time | date:'mm' }}</span>
<span> : </span>
<span class="seconds">{{ time | date:'ss' }}</span>

Chrome and Firefox are displaying 10 : 39 : 37 which is correct.

PhantomJS with 'require('intl/locale-data/jsonp/en.js')' in karma-shim.js displays 10 : 10:39 AM : 39:37

PhantomJS with 'require('intl/locale-data/jsonp/fr.js')' in karma-shim.js displays 10 : 10:39 : 39:37

If i want to have the format i'm expecting with fr.js (which is my purpose), I just have to add these too following properties to date.formats.availableFormats :

"m": "mm",
"s": "ss",

I'm not sure if this is a good correction, but i'm pretty sure this is a bug.

@caridy
Copy link
Collaborator

caridy commented Apr 20, 2017

We don't really produce those, we bring them from CLDR, feel free to open a bug for them: unicode.org/cldr/trac/newticket

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants