feat: add debug option for Electron development

- Introduced a new command `dev:electron:debug` in both package.json files to launch Electron with DevTools open.
- Updated main.js to conditionally open DevTools based on the `OPEN_DEVTOOLS` environment variable.
- Refactored some IPC handler code for better readability and consistency.
This commit is contained in:
Cody Seibert
2025-12-11 21:21:59 -05:00
parent 2cc9e47747
commit ada2703d3e
3 changed files with 70 additions and 50 deletions

View File

@@ -18,6 +18,7 @@
"dev": "next dev -p 3007",
"dev:web": "next dev -p 3007",
"dev:electron": "concurrently \"next dev -p 3007\" \"wait-on http://localhost:3007 && electron .\"",
"dev:electron:debug": "concurrently \"next dev -p 3007\" \"wait-on http://localhost:3007 && OPEN_DEVTOOLS=true electron .\"",
"build": "next build",
"build:electron": "next build && electron-builder",
"start": "next start",