Encodes a buffer by trimming leading zero bytes.
Finds the first non-zero byte and returns a new buffer starting from that byte. Returns an empty buffer if all bytes are zero.
encodeCompactFixedHexBlob(buffer): Uint8Array
Parameters
buffer: Uint8Array
The buffer to be compacted.
Returns Uint8Array
A Uint8Array instance compacted of leading zero bytes, or an empty Uint8Array if all bytes are zero.
Encodes a buffer by trimming leading zero bytes. Finds the first non-zero byte and returns a new buffer starting from that byte. Returns an empty buffer if all bytes are zero.