• Returns the number of bytes required to encode the given string into UTF-8. Throws if the source string has invalid UTF-16 encoding.

    Parameters

    • s: string

    Returns number