Browse Source

Update index.js to make it work with recent Electron (#119)

- Ensure enough windows size to show the tool bar
- Disable nodeIntegration to allow that jQuery without modification
  https://electronjs.org/docs/faq#i-can-not-use-jqueryrequirejsmeteorangularjs-in-electron
master
Nobuto Murata 8 months ago
parent
commit
4a16b95d25
1 changed files with 8 additions and 1 deletions
  1. 8
    1
      index.js

+ 8
- 1
index.js View File

@@ -10,7 +10,14 @@ const url = require('url')
let mainWindow;

function createWindow () {
mainWindow = new BrowserWindow({width: 800, height: 600, icon: path.join(__dirname, 'images', 'favicon.png')});
mainWindow = new BrowserWindow({
width: 1024,
height: 768,
icon: path.join(__dirname, 'images', 'favicon.png'),
webPreferences: {
nodeIntegration: false
}
});
mainWindow.setMenu(null);
mainWindow.loadURL(url.format({
pathname: path.join(__dirname, 'index.html'),

Loading…
Cancel
Save