1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-12-21 16:18:28 +01:00
bitwarden-browser/apps/desktop/src/preload.ts

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

25 lines
719 B
TypeScript
Raw Normal View History

import { contextBridge } from "electron";
import auth from "./auth/preload";
import keyManagement from "./key-management/preload";
import platform from "./platform/preload";
/**
* Bitwarden Preload script.
*
* This file contains the "glue" between the main process and the renderer process. Please ensure
* that you have read through the following articles before modifying any preload script.
*
* https://www.electronjs.org/docs/latest/tutorial/tutorial-preload
* https://www.electronjs.org/docs/latest/api/context-bridge
*/
// Each team owns a subspace of the `ipc` global variable in the renderer.
export const ipc = {
auth,
platform,
keyManagement,
};
contextBridge.exposeInMainWorld("ipc", ipc);