diff --git a/electron/main/index.ts b/electron/main/index.ts index f45bd76..8f0c0f7 100644 --- a/electron/main/index.ts +++ b/electron/main/index.ts @@ -98,10 +98,9 @@ ipcMain.handle('open-win', (event, arg) => { }, }) - if (app.isPackaged) { - childWindow.loadFile(indexHtml, { hash: arg }) - } else { + if (process.env.VITE_DEV_SERVER_URL) { childWindow.loadURL(`${url}#${arg}`) - // childWindow.webContents.openDevTools({ mode: "undocked", activate: true }) + } else { + childWindow.loadFile(indexHtml, { hash: arg }) } })