Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save gdonega/e770a28417933f1afba82b769cda66bd to your computer and use it in GitHub Desktop.
Save gdonega/e770a28417933f1afba82b769cda66bd to your computer and use it in GitHub Desktop.
...
function createWindow () {
/**
* Initial window options
*/
mainWindow = new BrowserWindow({
height: 563,
useContentSize: true,
width: 1000,
webPreferences: {
nodeIntegration: true,
nodeIntegrationInWorker: true
}
})
mainWindow.loadURL(winURL)
mainWindow.on('closed', () => {
mainWindow = null
})
}
app.allowRendererProcessReuse = true
app.on('ready', createWindow)
app.on('window-all-closed', () => {
if (process.platform !== 'darwin') {
app.quit()
}
})
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment