@nevware21/ts-utils
    Preparing search index...

    Function encodeAsBase64

    • Encode a string value as Base64. Text containing characters above U+00FF is encoded as the UTF-8 byte order mark followed by its UTF-8 bytes, so it can be restored by the matching decode function. All other text is encoded as one byte per character.

      Parameters

      • value: string

        The string value to encode

      Returns string

      The Base64 encoded string

      0.13.0

      encodeAsBase64("Hello"); // "SGVsbG8="
      encodeAsBase64("Hello World"); // "SGVsbG8gV29ybGQ="
      encodeAsBase64(""); // ""
      encodeAsBase64("€"); // "77u/4oKs"