Documentation
    Preparing search index...

    Function decodeWebrtcBytes

    • Decode canonical padded base64 WebrtcBytes text, rejecting every non-canonical form (missing padding, non-zero pad bits, whitespace, the URL-safe alphabet, a data-URL prefix).

      Parameters

      • value: unknown

        Candidate WebrtcBytes text.

      Returns Uint8Array<ArrayBufferLike> | undefined

      The decoded bytes, or undefined when value is not canonical.

      decodeWebrtcBytes('AAEC/w=='); // Uint8Array [0, 1, 2, 255]
      decodeWebrtcBytes('AAEC/x=='); // undefined: non-zero pad bits