decodeStringKey(
bytes,offset?): readonly [string,number]
Defined in: packages/key-encoding/src/scalars.ts:230
Decode one encodeStringKey encoding at offset, returning the string and the offset after its terminator.
Parameters
Section titled “Parameters”Uint8Array
offset?
Section titled “offset?”number
Returns
Section titled “Returns”readonly [string, number]
Throws
Section titled “Throws”INVALID_KEY_VALUE or INVALID_OFFSET, as decodeUint32Key.
Throws
Section titled “Throws”TRUNCATED_KEY, INVALID_ESCAPE_SEQUENCE, or TRAILING_BYTES, as
decodeBytesKey, or INVALID_UTF8 when the payload is not well-formed UTF-8.