3 ms·
One reason is it should not have been there in the first place. Due to it's age, if you google / stackoverflow something, the odds are very high a jQuery respo
by rstuart4133 8y ago
One reason is it should not have been there in the first place. Due to it's age, if you google / stackoverflow something, the odds are very high a jQuery response will be among the top hits. And so you end up with some jQuery dependency.
Back in the day when you had to target IE-6 that made sense - the web was so broken you really needed something it jQuery to render it sane. But that time has gone now, and I can't count the number of times the jQuery solution actually used more core than raw js.
Doing this is positively harmful. Not only is it slower and creates clashing dependencies because library A wants jQuery version B, but library Y wants version jQuery Z, it forces the programmers to learn the 10'th different way of doing something (there are always at least 10 libraries that do it). It's unnecessary because there is one thing every javascript programmer should know (and it's not jQuery) - it's modern javascript and the standard library provided by a IE9+ browser. If it can be done with a few lines that then that is how you should do it - because it makes like so much easier for those who follow you.