electron/spec/fixtures/api/window-open-preload.js
2018-09-14 14:57:01 +10:00

8 lines
219 B
JavaScript

const { ipcRenderer } = require('electron')
setImmediate(function () {
if (window.location.toString() === 'bar://page') {
ipcRenderer.send('answer', process.argv, typeof global.process)
window.close()
}
})