fileset-desktop/preload.js

10 lines
248 B
JavaScript
Raw Permalink Normal View History

2022-04-05 21:26:02 +08:00
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));
}