-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Open
Description
Currently int the non-deterministic mode LANG
is overwritten by :
emscripten/src/library_wasi.js
Line 47 in fbc5d5c
var lang = ((typeof navigator == 'object' && navigator.languages && navigator.languages[0]) || 'C').replace('-', '_') + '.UTF-8'; |
that is okay when we are using browser. However, when we are using NodeJS that does not have navigator
, we are overwritting the LANG
variable. It is really problematic because we still do not have a chance to set the desired locale.
My suggestion would be to pass the process.env.LANG
if it's available.
var lang = ENVIRONMENT_IS_NODE ? process.env.LANG : ((typeof navigator == 'object' && navigator.languages && navigator.languages[0]) || 'C').replace('-', '_') + '.UTF-8';
Metadata
Metadata
Assignees
Labels
No labels