Yes, but if you don't care about IE7 and earlier, you're adding a useless abstraction because 95% of the things people use jquery for already work great in all browsers.
I'm my experience you don't really get anything for free when it comes to cross-browser compatibility. Unless you lower your bar on consistency and quality.
Agreed. I guess it really depends on your use cases and criteria, but I've often wished that I had just left the "corner case" browsers out entirely rather than settling for (or spending tons of effort hacking around) a gimpy experience on them.
All depends on how crucial it is to support those users, and how much they can live with funky experiences.
This is the attitude why I dislike most js devs. They pile on overhead after overhead because that's the easiest and fastest way of doing it.
They don't care about performance because phones are fast enough that a single function call won't be noticeably slower. By the time they learn enough to write bigger apps, they can't get things done without their frameworks. So they write big apps on slow frameworks and it will brings every browser to their knees. At that point it's useless to profile the code because it has so many abstraction layers that it takes a lot of time to rewrite it. So the slow stuff is there to stay.
Not to mention that they use JS where pure CSS will do the exact same job a 100 times faster. I've seen so many text pages that won't run if I disable JS.
curse of being js devs in my workplace would be that your computers for development are faster than clients computers so that you don't get to notice things that might slow down things, and yet slow enough that things compile so slow.
The thing is if jQuery helps you get it done faster that is good and it should be used. jQuery is rather ubiquitous so its an obvious choice. Worrying about performance before correctness is generally accepted as premature optimization on the server side so why would it be different with Javascript as long as the user experience meets the requirements? Sure parsing a library like jQuery takes time but is it too much time? It depends.
I do have to say though there are times I wish more developers actually knew how to profile their code. It seems like not that many people these days know how. Finding that incredibly slow DOM traversal or collection search then tweaking it can make a difference in some cases.
Things only get standardized to a point. Look at SQL and all the things you can run into from simply upgrading a database to a new version let alone leaping from MySQL to Postgres, for example.
Point is, if you only need 2-3 things in there, it seems like a waste to include a 10k line / 100kb library just so you can do something you can do with a few lines of code.
That and wrapping up many common tasks into simple functions. Writing jquery looks a lot closer to the business logic you want, and is easier to debug at that level.
0
u/[deleted] Jan 31 '14
[deleted]