config file loading and saving

This commit is contained in:
2024-06-03 16:32:05 +02:00
parent 57ece16e14
commit c4cc2170f5
7 changed files with 149 additions and 52 deletions
+7
View File
@@ -0,0 +1,7 @@
const { contextBridge, ipcRenderer } = require('electron/renderer')
contextBridge.exposeInMainWorld('electronAPI', {
save: (configData) => ipcRenderer.send('save-config', configData),
cancel: () => ipcRenderer.send('cancel-config'),
onUpdate: (callback) => ipcRenderer.on('update-config', (_event, configData) => callback(configData))
});