7 ms·
Looks like this issue is pervasive in other languages as well. Out of curiosity ran the same test in Javascript and received the same result. s = "We went t
by hmmdar 13y ago
Looks like this issue is pervasive in other languages as well. Out of curiosity ran the same test in Javascript and received the same result.
s = "We went to eat at multiple cafe\u0301"
"We went to eat at multiple café"
s.replace('cafe', 'cafes');
"We went to eat at multiple cafeś"
Interesting thing is when the text is copy-pasted backspacing first deletes the accent. At least in chrome.
- lstamour 13y agoFYI: Node.js - https://github.com/walling/unorm https://github.com/walling/unorm YMMV, but looks good. It can also serve as a polyfill for the eventual http://people.mozilla.org/~jorendorff/es6-draft.html#sec-string.prototype.normalize http://people.mozilla.org/~jorendorff/es6-draft.html#sec-str...