fileset-desktop/preload.js

10 lines
248 B
JavaScript

const { contextBridge } = require("electron");
const ipc = require("./ipc/ipc").ipc;
const getAPI = require("./ipc/ipc").getAPI;
console.log(ipc);
for (const key in ipc) {
console.log(key);
contextBridge.exposeInMainWorld(key, getAPI(key));
}