JavaScript

Intl.Locale.prototype.collation プロパティ


編集:2023.01.10 by T.A.

[Edge]。→

Intl.Locale の比較の種別を表す文字列を返します。

構文
Intl.Locale.collation
Intl.Locale Intl.Locale

文字列。→Intl.Collator():collation

DA=new Intl.Locale('ja-JP');  //日本語の日本国。
D=DA.collation;  //=[undefined]:undefined
DA=new Intl.Locale('ja-JP-u-co-eor');  //日本語の日本国、比較方法。
D=DA.collation;  //=[string]:eor
DA=new Intl.Locale('ja-JP', {collation:'eor'});  //日本語の日本国、比較方法。
D=DA.collation;  //=[string]:eor

//●設定可能?
DA=new Intl.Locale('ja-JP');  //日本語の日本国。
DA.collation='eor';
D=DA.collation;  //=[undefined]:undefined
	//読み取り専用のようです。

Intl.Locale()


テスト