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

Support all ECMA-402 formatter options? #328

Open
rxaviers opened this issue Oct 3, 2014 · 3 comments
Open

Support all ECMA-402 formatter options? #328

rxaviers opened this issue Oct 3, 2014 · 3 comments
Labels

Comments

@rxaviers
Copy link
Member

rxaviers commented Oct 3, 2014

Number format

ECMA-402 options Globalize options
localeMatcher 🚫 Not needed, locales are not negotiated
style style
currency currency
currencyDisplay currencyDisplay
useGrouping useGrouping
minimumIntegerDigits minimumIntegerDigits
minimumFractionDigits minimumFractionDigits
maximumFractionDigits maximumFractionDigits
minimumSignificantDigits minimumSignificantDigits
maximumSignificantDigits maximumSignificantDigits
🚫 round

Date format

ECMA-402 options Globalize options
localeMatcher 🚫 Not needed, locales are not negotiated
timeZone 🚫
hour12 🚫
formatMatcher 🚫
era era via skeleton
year year via skeleton
🚫 quarter via skeleton
month month via skeleton
🚫 week of year via skeleton
🚫 week of month via skeleton
weekday weekday via skeleton
day day via skeleton
hour hour via skeleton
minute minute via skeleton
second second via skeleton
timeZoneName timeZoneName via skeleton
❗ fields combination? [1] ❗ all combinations possible after implementing #271 #272
🚫 {date: "full
🚫 {time: "full
🚫 {datetime: "full

1: According to MDN:

Implementations are required to support at least the following subsets

  • weekday, year, month, day, hour, minute, second
  • weekday, year, month, day
  • year, month, day
  • year, month
  • month, day
  • hour, minute, second
  • hour, minute

How about other subsets?

@jzaefferer
Copy link
Contributor

There's also the question of using an Intl polyfill in place of our own formatters or making Globalize an Intl polyfill. Looking at the red signs about, neither is currently possible. I'm not sure which one is more likely to happen or of interest to anyone. I think its worth implementing all ECMA-402 options in Globalize, so we should at least investigate what effort is involved in that.

@mwmw7
Copy link

mwmw7 commented Mar 24, 2015

first , i think we need a performance test with ECMA-402

@rxaviers
Copy link
Member Author

@mwmw7 perf tests are welcome. Related issues: #274 and #397.

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

No branches or pull requests

3 participants