method TextEncoder.prototype.encodeTextEncoder.prototype.encode(input?: string): Uint8ArrayDeprecatedUTF-8 encodes the input string and returns a Uint8Array containing the encoded bytes. Parametersoptionalinput: string = 'an empty string'The text to encode. Return TypeUint8Array