electron-ipc-module
    Preparing search index...

    Function defineIpcEvents

    • Declare the map of events a module emits to the renderer, purely for typing.

      Returns an empty object typed as TEvents; it carries no runtime value. The Rollup bridge plugin reads the TEvents type argument to generate typed on* / once* listeners in the preload bridge.

      type ProfileEvents = { "profile-updated": [profile: Profile] };
      export const profileEvents = defineIpcEvents<ProfileEvents>();

      Type Parameters

      Returns TEvents