Function convertStringToBase64String

Converts/Encodes a String into Base64 (URI) encoded string. UTF-8 is supported. Inverse function convertBase64StringToString

  • Parameters

    • str: string

      The string to be converted

    • isURICompatible: boolean = true

      Determine whether the resulting string shall be URI compatible, or not. Default is true

    Returns string

    The Base64 String representing the input string. The string is already URI encoded, i.e. can be used directly in browsers