Skip to content

Commit

Permalink
upd electron context
Browse files Browse the repository at this point in the history
  • Loading branch information
freekode committed Feb 21, 2024
1 parent 08e3bdb commit ed412de
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions electron/src/preload/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { contextBridge, ipcRenderer } from 'electron';
import { contextBridge } from 'electron';
import {
appVersionSupplier,
bootAddressSupplier,
Expand All @@ -7,8 +7,10 @@ import {
subscriptions
} from "./renderer";

contextBridge.exposeInMainWorld('bootAddress', bootAddressSupplier())
contextBridge.exposeInMainWorld('bootHealthy', bootHealthySupplier());
contextBridge.exposeInMainWorld('appVersion', appVersionSupplier());
contextBridge.exposeInMainWorld('appPlatform', platformSupplier());
contextBridge.exposeInMainWorld('subscriptions', subscriptions);
contextBridge.exposeInMainWorld('electron', {
bootAddress: bootAddressSupplier(),
bootHealthy: bootHealthySupplier(),
appVersion: appVersionSupplier(),
appPlatform: platformSupplier(),
subscriptions: subscriptions,
})

0 comments on commit ed412de

Please sign in to comment.