API reference › @evolu/common › local‑first/Protocol › createProtocolMessageFromCrdtMessages
function createProtocolMessageFromCrdtMessages(
deps: RandomBytesDep,
): (
owner: Owner,
messages: readonly [CrdtMessage, CrdtMessage],
maxSize?: number & Brand<"Int"> & Brand<"Between1000000-100000000">,
) => ProtocolMessage;
Defined in: packages/common/src/local-first/Protocol.ts:489
Creates a ProtocolMessage from CRDT messages.
If the message size would exceed defaultProtocolMessageMaxSize, the protocol ensures all messages will be sent in the next round(s) even over unidirectional and stateless transports.