4 ms·
I don't think that's accurate (or fair, really). Jquery was one in a list of dozens of libraries that did similar things at that time, but ajax/interactivity ha
by wambotron 11y ago
I don't think that's accurate (or fair, really). Jquery was one in a list of dozens of libraries that did similar things at that time, but ajax/interactivity had been part of the web mindset for years before jquery existed. Jquery just won the library war.
- swang 11y agoYep, I'm surprised jQuery isn't older, as I do recall using dojo and prototype before 2006. jQuery was a huge timesaver, as was dojo, mootools, prototype, etc and not having at least one of these libraries would have sucked. And although jQuery "won" it could have easily been any other javascript library. Even if these libraries somehow didn't exist, there was tons of cross-browser snippets plastered across the web that dealt with most of the common problems (ajax, event listeners, etc).
- gregmac 11y agoWhat drew me to jQuery over Prototype in particular was the fact you could use css-style selectors to get and operate on several elements at once. This often reduced several lines of code in a loop to a couple chained methods. Prototype first came out in Feb 2005. Dojo 0.1 was Aug 2005, and 1.0 (first stable, after a total rewrite) was Nov 2007. I do remember using Prototype with script.aculo.us and thinking it was pretty neat to add some effects to my server-side-created web apps, but that they'd largely stay server side. The first time I saw jQuery, that was when I thought "Yeah, okay, we can actually start building some serious client-side interactions here" instead of just server-generated HTML pages. jQuery took me from hating (but tolerating) javascript to actually enjoying client-side web development.
- underwater 11y agojQuery was important not just because of the feature set, but because it completely dominated the industry. jQuery and its ecosystem of plugins created a single community for JS developers. A lot of subsequent work wouldn't have been as successful without that strong community in place to spread ideas. The other thing it did well was change the thinking about how JavaScript should interact with the DOM. In the past you'd have libraries that made DOM access easier, but they largely followed the same conventions as the underling APIs. jQuery broke from that and completely re-envisioned the API layer. The underlying APIs were treated as an implementation detail; this approach is something that subsequent libraries have adopted too.
- vatotemking 11y agoExactly. Method chaining was a novel feature back then
- deleted 11y ago[deleted]
- rudolf0 11y agoIt won because it has a great API and excellent documentation. jQuery is pretty much the only library or framework made 10+ years ago I can use and still feel like "this is actually well-designed". Frameworks generally obviate the need for it, but if a framework isn't an option and if I'm going to be writing more than 100 lines of code (otherwise I'd suck it up and use plain JS), I always still use jQuery.