Skip to content

lib: set default ICU locale per cli option `--icu-locale`

This PR adds a standardized way via the cli option --icu-locale to set the default locale of the ICU used in node process.

How to use:

node --icu-locale=fr-FR

then in the repl you can do

console.log(Intl?.Collator().resolvedOptions().locale) // output is 'fr-FR'

Todo:

  • get feedback if it is implemented correctly from other maintainers
  • add tests
  • add documentation

Merge request reports

Loading