2017-04-04 20:39:24 +00:00
|
|
|
/*
|
|
|
|
* Pending electron 1.6.x
|
|
|
|
* const env = require('url').parse(window.location, true).query;
|
|
|
|
*/
|
|
|
|
|
|
|
|
window.env = {};
|
|
|
|
window.location.search.substring(1).split('&').forEach(function(variable) {
|
|
|
|
var pair = variable.split('=');
|
|
|
|
env[decodeURIComponent(pair[0])] = decodeURIComponent(pair[1]);
|
|
|
|
});
|
2017-04-04 06:32:46 +00:00
|
|
|
|
|
|
|
const ipc = require('electron').ipcRenderer
|
|
|
|
window.env.locale_json = ipc.sendSync('locale-data');
|