Variable protoBase64Const

protoBase64: {
    dec: ((base64Str) => Uint8Array);
    enc: ((bytes) => string);
}

Type declaration

  • Readonly dec: ((base64Str) => Uint8Array)

    Decodes a base64 string to a byte array.

    • ignores white-space, including line breaks and tabs
    • allows inner padding (can decode concatenated base64 strings)
    • does not require padding
    • understands base64url encoding: "-" instead of "+", "_" instead of "/", no padding
      • (base64Str): Uint8Array
      • Parameters

        • base64Str: string

        Returns Uint8Array

  • Readonly enc: ((bytes) => string)

    Encode a byte array to a base64 string.

      • (bytes): string
      • Parameters

        • bytes: Uint8Array

        Returns string