diff --git a/main/src/index.ts b/main/src/index.ts index 9f0f5271..fc6c6724 100644 --- a/main/src/index.ts +++ b/main/src/index.ts @@ -71,6 +71,28 @@ if (isDuplicateInstance) { function createWindow() { const window = new AppWindow(); + if (__DEV__) { + const { + default: installExtension, + REDUX_DEVTOOLS + } = require('electron-devtools-installer'); + + require('electron-debug')({ showDevTools: true }); + + const ChromeLens = { + id: 'idikgljglpfilbhaboonnpnnincjhjkd', + electron: '>=1.2.1' + }; + + const extensions = [REDUX_DEVTOOLS, ChromeLens]; + + for (const extension of extensions) { + try { + installExtension(extension); + } catch (e) {} + } + } + window.onClose(() => { appWindow = null; if (!__DARWIN__ && !preventQuit) {