Trilium Electron API
    Preparing search index...

    Interface ElectronApi

    The complete surface exposed to the renderer as window.electronApi via contextBridge. The renderer must access Electron-only functionality through this object — direct require("electron") and @electron/remote are unavailable because nodeIntegration is disabled and contextIsolation is enabled.

    The runtime value lives in apps/desktop/src/preload.ts; this interface is the contract both the preload script (satisfies ElectronApi) and the client (window.electronApi) share.

    Index

    Properties

    System clipboard access beyond what the standard Web Clipboard API offers.

    Native context-menu plumbing for right-click events on web contents.

    Read/write access to Chromium's back/forward navigation history.

    OneNote importer sign-in via a loopback OAuth redirect (desktop only).

    Printing and PDF export pipeline.

    Security settings (backend scripting, SQL console) stored outside the DB.

    Shell integration — opening URLs, files, and downloads with OS handlers.

    Chromium spell checker controls (dictionary, language list).

    systemIntegration: ElectronSystemIntegrationApi

    OS integration — system tray and autostart / launch-on-login.

    Window chrome, zoom, theme, lifecycle, and main → renderer events.

    In-process bridge that replaces the renderer↔server WebSocket.