MCPcopy Create free account
hub / github.com/tinyplex/tinybase / registerReceive

Function registerReceive

src/synchronizers/synchronizer-ws-client/index.ts:38–44  ·  view source on GitHub ↗
(receive: Receive)

Source from the content-addressed store, hash-verified

36 };
37
38 const registerReceive = (receive: Receive) => {
39 const receivePayload = createPayloadReceiver(
40 receive,
41 requestTimeoutSeconds,
42 );
43 addEventListener(MESSAGE, ({data}) => receivePayload(data.toString(UTF8)));
44 };
45
46 const send = (
47 toClientId: IdOrNull,

Callers

nothing calls this directly

Calls 3

createPayloadReceiverFunction · 0.90
addEventListenerFunction · 0.70
receivePayloadFunction · 0.50

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…