Skip to content

electron-messageport-trpc

Type-safe IPC for Electron using tRPC v11 and MessagePort

End-to-End Type Safety

Full TypeScript inference from your router definition to the renderer client. No more untyped channel names.

Structured Clone

MessagePort uses the Structured Clone algorithm — Date, Map, Set, and ArrayBuffer are transferred natively without JSON serialization.

Flexible Topology

Go beyond the star topology of ipcMain/ipcRenderer. Keep standard renderer-to-main flows, or connect main and renderer clients to utility processes over MessagePort.

tRPC v11 Subscriptions

Real-time streaming via async iterables. Subscribe from the renderer and receive live updates from the main process.