tc39 / proposal-intl-duration-format

https://tc39.es/proposal-intl-duration-format
MIT License
163 stars 18 forks source link

Table 3 looks broken for fractional units #196

Closed sffc closed 4 months ago

sffc commented 4 months ago

I'm looking at Table 3:

image

"fractional" was supposed to be an internal change, but based on this table, it looks like we're accepting it from the public options bag.

Also, why is "fractional" the default for microseconds and nanoseconds but not milliseconds?

@ben-allen @FrankYFTang

sffc commented 4 months ago

Note: the spec says

  1. For each row of Table 3 ... ... d. Let valueList be the Values value of the current row. ... f. Let unitOptions be ? GetDurationUnitOptions(unit, options, style, valueList, digitalBase, prevStyle).

which calls GetOption with the value list.

ben-allen commented 4 months ago

Fixed by https://github.com/tc39/proposal-intl-duration-format/pull/197