`\s` is supposedly sugar for `[ \f\n\r\t\v​\u00a0\u1680​\u180e\u2000​\u2001\u2002​\u2003\u2004​\u2005\u2006​\u2007\u2008​\u2009\u200a​\u2028\u2029​​\u202f\u205f​\u3000]` so it matches a lot of other whitespace as well which does IE8 does *not* collapse. However, your comment prompted be to do a more thorough test and it apparently also treats `\f` as whitespace. So I should add that, but in practice, `\s` could be used, it's not invasive, it's simply just more costly (and these are very much extremely unlikely special cases). Prefer that I add `\f` or switch to `\s`?

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions