I never caught on to the whole jQuery hype. Why do people use jQuery for such trivial things such as DOM? Wouldn't it be smarter to use getElementById() and end up with universal code that could run on any site without the need for 3rd party libraries?
- Do you remember which events IE conveniently forgets about, like not bubbling "submit" events above forms?
- Can you write out AJAX code that reliably works in all versions of IE by memory? And don't forget to add automatic jsonp support for cross-domain requests.
- Do you remember how to get the width and outerWidth of an element in a reliable cross-browser way?
There was a time when I could do these things from memory. That time was when I was interviewing for jobs. In daily work, I only have to half-remember these things and can operate at a higher level of abstraction.
Because the job is rarely just manipulating the Dom in some simple way.
Sure, if you just want to add the current date to <div id="rightNow"> then use basic browser builtins, but it's usually more like "I need every other child of each list with the class 'rowStripe' unless it's the last entry in the list", in which case jquery saves you a ton of time.
I find that jQuery gives you a lot more than just DOM manipulation. If you were doing just that then JQuery is overkill. But JQ gives you a lot more in the way of animations, plugins, and all sorts of other useful methods.
I also like the community. There seems to be a jquery plugin for damn near everything. Kind of like PHP. Yes it can be a mess. But when you are just trying to "get shit done" JQuery isn't bad at all.
For me, it has always been about creating unified interface across all the different browsers. While getElementID is universally supported, many things are different (see all the remarks about setting the `name` attribute on elements in Internet Explorer http://msdn.microsoft.com/en-us/library/ms534184%28VS.85%29....).
I'd rather let the library developers abstract all that out for me.
Cross-browsers. If we only had Firefox, then ya, there could be some debate. Jquery handles cross-browser problems, while at the same time providing a more intuitive DOM manipulation layer. What more can you ask for? Use Jquery, build better things, move forward.