Avoid insecure nodeIntegration in example

This commit is contained in:
Birunthan Mohanathas 2017-04-13 01:05:19 +03:00
parent ccdeb4746e
commit 000aedf2e7

View file

@ -23,7 +23,11 @@ win.on('closed', () => {
win = null win = null
}) })
let view = new BrowserView() let view = new BrowserView({
webPreferences: {
nodeIntegration: false
}
})
win.addChildView(view) win.addChildView(view)
view.setBounds(0, 0, 300, 300) view.setBounds(0, 0, 300, 300)
view.webContents.loadURL('https://electron.atom.io') view.webContents.loadURL('https://electron.atom.io')