redux-devtools/extension/test/electron/fixture/main.js
renovate[bot] 922985f9ea
chore(deps): update dependency prettier to v3 (#1434)
* chore(deps): update dependency prettier to v3

* Format

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Nathan Bierema <nbierema@gmail.com>
2023-07-12 18:03:20 +00:00

22 lines
561 B
JavaScript

const path = require('path');
const { app, BrowserWindow, session } = require('electron');
app.on('window-all-closed', app.quit);
app.whenReady().then(async () => {
await session.defaultSession.loadExtension(
path.join(__dirname, '../../../dist'),
{ allowFileAccess: true },
);
const mainWindow = new BrowserWindow({
width: 150,
height: 100,
webPreferences: {
nodeIntegration: true,
contextIsolation: false,
},
});
mainWindow.loadFile('index.html');
mainWindow.webContents.openDevTools({ mode: 'detach' });
});