mirror of
https://github.com/GNS3/gns3-web-ui.git
synced 2025-06-17 06:18:09 +00:00
Fonts&icons offline in electron app, Fixes: #94
This commit is contained in:
11
main.js
11
main.js
@ -18,8 +18,10 @@ let isDev = false;
|
||||
const argv = yargs
|
||||
.describe('m', 'Maximizes window on startup.')
|
||||
.boolean('m')
|
||||
.describe('e', 'Environment, `dev` for developer mode and when not specified then production mode. ')
|
||||
.describe('e', 'Environment, `dev` for developer mode and when not specified then production mode.')
|
||||
.choices('e', ['dev', null])
|
||||
.describe('d', 'Enable developer tools.')
|
||||
.boolean('d')
|
||||
.argv;
|
||||
|
||||
if (argv.e == 'dev') {
|
||||
@ -75,7 +77,6 @@ function createWindow () {
|
||||
|
||||
if(isDev) {
|
||||
mainWindow.loadURL('http://localhost:4200/');
|
||||
mainWindow.webContents.openDevTools();
|
||||
}
|
||||
else {
|
||||
mainWindow.loadURL(url.format({
|
||||
@ -85,8 +86,10 @@ function createWindow () {
|
||||
}));
|
||||
}
|
||||
|
||||
// Open the DevTools.
|
||||
// mainWindow.webContents.openDevTools();
|
||||
if(argv.d) {
|
||||
// Open the DevTools.
|
||||
mainWindow.webContents.openDevTools();
|
||||
}
|
||||
|
||||
if(argv.m) {
|
||||
mainWindow.maximize();
|
||||
|
Reference in New Issue
Block a user