Files
2026-04-16 05:02:57 +00:00

9 lines
308 B
JavaScript

const { contextBridge, ipcRenderer } = require('electron');
// Expose protected methods that allow the renderer process to use
// ipcRenderer without exposing the entire object
contextBridge.exposeInMainWorld('electron', {
isElectron: true,
getAppInfo: () => ipcRenderer.invoke('get-app-info'),
});