That won't work on Android 2.x, which doesn't support `.classList`. Performance isn't even an issue here since changing classes will cause a reapply-styles and layout.
I care as much for Android 2.x as ie below 10.
And probably 80% of our startup's revenue comes from banks stuck using IE8.
Is there a http://mapthebanks.com / https://news.ycombinator.com/item?id=8753565 for tracking technology organizations use?
Note the Jquery ticket for this issue can be tracked link below. In most cases Jquery will try to use to native implementations this is the ticket in this case they've never found it to be "miles away more performant".
So this:
Can become to this: And is miles away more performant than slow jQuery.