feat: window.app add app path

This commit is contained in:
kangfenmao
2024-08-16 22:44:00 +08:00
parent aa38e60b1d
commit 44cf2fcb26
2 changed files with 3 additions and 1 deletions
+2 -1
View File
@@ -107,7 +107,8 @@ app.whenReady().then(() => {
// IPC
ipcMain.handle('get-app-info', () => ({
version: app.getVersion(),
isPackaged: app.isPackaged
isPackaged: app.isPackaged,
appPath: app.getAppPath()
}))
ipcMain.handle('open-website', (_, url: string) => {
+1
View File
@@ -7,6 +7,7 @@ declare global {
getAppInfo: () => Promise<{
version: string
isPackaged: boolean
appPath: string
}>
checkForUpdate: () => void
openWebsite: (url: string) => void