3 ms·
I hit a similar problem in an application that was performing non-unicode-aware string operations on user-submitted text in a typescript codebase. The data coul
by denzen 5mo ago
I hit a similar problem in an application that was performing non-unicode-aware string operations on user-submitted text in a typescript codebase. The data couldn't be processed by an external service that was expecting valid Unicode. My fix was using toWellFormed: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/toWellFormed https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...