• Encode data with either hex or base64.

    Parameters

    • data: Uint8Array

      Data to encode.

    • encoding: Encoding

      Encoding to use: base64 or hex

    Returns string

    Encoded value.