-
Notifications
You must be signed in to change notification settings - Fork 107
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
Add "collation" option to Intl.Collator #380
Comments
I'm +1 for this. There is some discussion about this on #105. @NorbertLindenberg said,
|
Here are some code example currently work in Firefox and Chrome by using the -u-co- extension in locale. Chinese
If we enable the "collation" option, then the code should be
Examples in Vietnamese
|
Collator already have "co" in [[RelevantExtensionKeys]] internal slot and therefore the usage by using "-u-co-$collationkey" is already supported in ECMA402. Close #380
The following html show the underline collation support is already build into Firefox, Chrome and Safari
|
* Allow Collator to get collation from option Collator already have "co" in [[RelevantExtensionKeys]] internal slot and therefore the usage by using "-u-co-$collationkey" is already supported in ECMA402. Close #380 * Move the reading of the collation option earlier To make it the same as the order already in Table 3: Resolved Options of Collator Instances * add reference of type to UTS 35 * change ` to * * change http to https
#175
add "calendar" and "numberingSystem" option to Intl.DateTimeFormat and Intl.NumberFormat
Also notice "numberingSystem" is already an option in Intl.RelativeTimeFormat.
We should also consider add "collation" to Intl.Collator.
Notes by @littledan in #175 stated
"This patch leaves out "collation" because of a lack
of clear use cases."
Not sure what does that mean.
I think it is useful. For example, in Chinese, we may construct the following collator
var pinyin = new Intl.Collator("zh", {collator: "pinyin"});
var zhuyin = new Intl.Collator("zh", {collator: "zhuyin"});
var stroke = new Intl.Collator("zh", {collator: "stroke"});
The text was updated successfully, but these errors were encountered: