Skip to main content

Module Cocoon

Module Cocoon 

Source
Expand description

Cocoon bridge atoms - renderer→Cocoon gRPC forwarding.

Request - two-way RPC (awaits a reply from Cocoon). Notify - fire-and-forget notification (no reply expected). ExtensionHostMessage - binary extension-host protocol relay.

Modules§

ExtensionHostMessage
Wire method: cocoon:extensionHostMessage. Relays binary extension-host protocol messages from Wind/Sky to Cocoon via gRPC GenericNotification. Fire-and-forget - the extension host protocol is fully async; Mountain does not await a reply.
Notify
Wire method: cocoon:notify. Fire-and-forget renderer→Cocoon notification bridge for one-way wire methods (webview.message, webview.dispose, webview.viewState, etc.) where the extension doesn’t reply. Returns null immediately; the notification dispatches asynchronously avoiding the 30 s request timeout.
Request
Wire method: cocoon:request. Generic renderer→Cocoon RPC bridge for two-way wire methods that expect a reply (e.g. webview.resolveView). Waits up to 5 s for the gRPC handshake before dispatching; allows up to 30 s for the Cocoon reply.