const { contextBridge, ipcRenderer } = require('electron') contextBridge.exposeInMainWorld('notesBridge', { getCredentials: () => ipcRenderer.invoke('credentials:get'), saveCredentials: credentials => ipcRenderer.invoke('credentials:save', credentials), clearCredentials: () => ipcRenderer.invoke('credentials:clear'), syncNotes: payload => ipcRenderer.invoke('notes:sync', payload), createNote: payload => ipcRenderer.invoke('notes:create', payload), updateNote: payload => ipcRenderer.invoke('notes:update', payload), deleteNote: payload => ipcRenderer.invoke('notes:delete', payload), })