Conversation

I agree that JS does not have UF16 but rather WTF16, but that is not a big deal, since all FFI crossings and UTF16 -> UTF8 conversions within the engines are sanitized and unpairad surrogates are replaced by U+FFFD. The Wasm IT discusses now how this sanitization will take place
1
UTF-8 uses at most 4 bytes for a code point, just like UTF-16. Emojis aren't in the BMP. UTF-16 needs the same amount of data to represent them. It takes 3 bytes for basic Chinese, Japanese and Korean characters rather than 2 but their markup is still 1 byte instead of 2.
1
Data starts as UTF-8 and ends up as UTF-8. Main string operation is appending. UTF-8 is faster from being smaller in nearly every case. What are you doing with text beyond reading, writing, appending (including formatting) and displaying it? UTF-8 is faster in the real world.
2
You don't need to decode UTF-8 to append strings and do formatting. It's smaller, so it's faster. A fast SIMD-accelerated UTF-8 decoder is ridiculously fast anyway. String performance is almost entirely about optimized memory allocation/layout and the best way is not needing it.
1