API reference › @evolu/common › local‑first/Protocol › encodeNonNegativeInt
function encodeNonNegativeInt(
buffer: Buffer,
int: number & Brand<"Int"> & Brand<"NonNegative">,
): void;
Defined in: packages/common/src/local-first/Protocol.ts:1982
Encodes a non-negative integer into a variable-length integer format. It's more efficient than encoding via encodeNumber.