Closed robintown closed 1 week ago
🤦 Good spot
There's also replaceAll
nowadays https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/replaceAll
I saw that, it would've required me to bump our TypeScript ES target though so I decided not to bother
String.replace
only replaces a single instance of the search pattern by default; we need a regex ing
mode if we want to replace them all.For https://github.com/element-hq/element-call/issues/2429