Decode a minimally-encoded CompactUint (Satoshi's variable-length, positive
integer format) from a Uint8Array, returning the value as a BigInt. This
function returns an error if the entire input is not consumed – to read a
CompactUint from a position within a larger Uint8Array,
use readCompactUintMinimal or readCompactUint.
Decode a minimally-encoded
CompactUint
(Satoshi's variable-length, positive integer format) from a Uint8Array, returning the value as a BigInt. This function returns an error if the entire input is not consumed – to read aCompactUint
from a position within a largerUint8Array
, use readCompactUintMinimal or readCompactUint.For the reverse, see bigIntToCompactUint.