Desktop: Fixes #8210: Display plugin console in dev mode

pull/8311/head
Laurent Cozic 2023-06-12 17:30:47 +01:00
parent 1eeb5ab471
commit 3c0331eb6e
1 changed files with 4 additions and 1 deletions

View File

@ -129,7 +129,10 @@ export default class PluginRunner extends BasePluginRunner {
if (plugin.devMode) {
pluginWindow.webContents.once('dom-ready', () => {
pluginWindow.webContents.openDevTools({ mode: 'detach' });
// Need to open with a delay, otherwise it doesn't show up
setTimeout(() => {
pluginWindow.webContents.openDevTools({ mode: 'detach' });
}, 3000);
});
}