fix: check for destroyed webcontents in converter (#25431)

This commit is contained in:
Jeremy Rose
2020-09-16 12:25:49 -07:00
committed by GitHub
parent 1ba46a91b6
commit ba55aaa53b
2 changed files with 15 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
const { app, BrowserWindow } = require('electron');
app.whenReady().then(() => {
const w = new BrowserWindow({ show: false, webPreferences: { webviewTag: true } });
w.loadURL('data:text/html,<webview src="data:text/html,hi"></webview>');
app.on('web-contents-created', () => {
w.close();
});
});