Subscribes to messages pushed from the main process. Returns an unsubscribe function — call it when the listener is no longer needed (e.g. when a BrowserWindow is unloaded) to avoid leaking handlers.
Sends a message from the renderer to the main-process messaging hub.
In-process replacement for the renderer↔server WebSocket. Backed by Chromium IPC instead of a TCP socket — no port is bound and no auth check is needed because the channel is only reachable from the renderer the BrowserWindow owns. Wire format is whatever the server's
MessagingProvideraccepts (currentlyWebSocketMessage/ log-error / log-info / ping).