electron dev tools is added
This commit is contained in:
parent
e78e4bb514
commit
07528f5629
|
@ -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) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user