Skip to content

Commit d70cd0a

Browse files
committed
feat: enable dev tools
1 parent c507bf6 commit d70cd0a

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

electron/main/app.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,11 @@ serve({ directory: appRendererPath });
3030

3131
const createWindow = async (): Promise<void> => {
3232
const mainWindow = new BrowserWindow({
33-
width: 800,
34-
height: 600,
33+
width: 1200,
34+
height: 800,
3535
webPreferences: {
3636
preload: path.join(appPreloadPath, 'index.js'),
37+
devTools: !app.isPackaged,
3738
/**
3839
* Security Best Practices
3940
* https://www.electronjs.org/docs/latest/tutorial/security

electron/main/menu/index.ts

+8
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,14 @@ function buildDarwinTemplate(
139139
window.setFullScreen(!window.isFullScreen());
140140
},
141141
},
142+
{
143+
label: 'Toggle Developer Tools',
144+
accelerator: 'Alt+Command+I',
145+
visible: !app.isPackaged,
146+
click: () => {
147+
window.webContents.toggleDevTools();
148+
},
149+
},
142150
{ type: 'separator' },
143151
{
144152
label: 'Reset Zoom',

0 commit comments

Comments
 (0)