mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
fix: set app locale after user's script is loaded (#26185)
* fix: set app locale after user's script is loaded * fix: set LC_ALL env on Linux
This commit is contained in:
3
spec/fixtures/api/locale-check/main.js
vendored
3
spec/fixtures/api/locale-check/main.js
vendored
@@ -1,5 +1,8 @@
|
||||
const { app } = require('electron');
|
||||
|
||||
const locale = process.argv[2].substr(11);
|
||||
app.commandLine.appendSwitch('lang', locale);
|
||||
|
||||
app.whenReady().then(() => {
|
||||
process.stdout.write(app.getLocale());
|
||||
process.stdout.end();
|
||||
|
||||
Reference in New Issue
Block a user