encoding.js
This file
Path
test/helpers/encoding.js
7 lines · 324 bytes · JavaScript
Last changed by
Add `binary` and `preserveNewlines` options to `subprocess.readable()` (#922)ehmickybefore adoption56ee48e
History of this fileTake it
Add `binary` and `preserveNewlines` options to `subprocess.readable()` (#922)ehmickybefore adoption56ee48e
lines 1–7why, one step back1const textEncoder = new TextEncoder();23export const multibyteChar = '\u{1F984}';4export const multibyteString = `${multibyteChar}${multibyteChar}`;5export const multibyteUint8Array = textEncoder.encode(multibyteString);6export const breakingLength = multibyteUint8Array.length * 0.75;7export const brokenSymbol = '\uFFFD';