TextEncoder & TextDecoder

TextEncoder & TextDecoder

TextEncoder encodes a JavaScript string into bytes using the UTF-8 encoding and returns the resulting Uint8Array of those bytes. TextDecoder does the reverse.

Spec https://encoding.spec.whatwg.org/#api
Status WHATWG Living Standard
IE Edge Firefox Chrome Safari Opera