Skip to main content

Class: Base58

Class to help with base58 Encoding/Decoding.

Table of contents

Methods

Constructors

Methods

decode

Static decode(base58): Uint8Array

Convert the base 58 string to a byte array.

throws If the input string contains a character not in the Base58 alphabet.

Parameters

NameTypeDescription
base58stringThe base58 string to convert.

Returns

Uint8Array

The byte array.


encode

Static encode(bytes): string

Convert a byte array to base 58.

Parameters

NameTypeDescription
bytesUint8ArrayThe byte array to encode.

Returns

string

The data as base58 string.

Constructors

constructor

new Base58()