redux-devtools/extension/test/electron/fixture/main.js
Nathan Bierema 6782f4ae41
chore(extension): add extension (#658)
* Move extension

* prettier
2020-10-26 08:18:23 -04:00

19 lines
486 B
JavaScript

const path = require('path');
const { app, BrowserWindow } = require('electron');
app.setPath('userData', path.join(__dirname, '../tmp'));
app.on('window-all-closed', app.quit);
app.on('ready', () => {
BrowserWindow.addDevToolsExtension(
path.join(__dirname, '../../../build/extension')
);
const mainWindow = new BrowserWindow({
width: 150,
height: 100,
});
mainWindow.loadURL(`file://${__dirname}/index.html`);
mainWindow.openDevTools({ detach: true });
});