The jQuery Cookbook: Solutions And Examples For jQuery Developers

Posted December 14, 2009 at 7:59 AM by Ben Nadel

Tags: Javascript / DHTML, Books

This weekend, I finished reading the jQuery Cookbook from O'Reilly, subtitled Solutions and Examples for jQuery Developers. The book is a collaborative effort of nineteen jQuery community experts covering well over 150 common jQuery and Javascript problems. Coming in at 435 pages, the jQuery Cookbook is full of great information and covers a huge variety of topics, some quite simple and some quite complex.


 
 
 

 
The jQuery Cookbook: Solutions And Examples For jQuery Developers.  
 
 
 

Without a doubt, there are a lot of great examples in this book. And, because they are written by community experts, not only do you learn to solve the given problems, you pick up a lot of very neat tips and tricks that are completely meta to the meaning of the code at hand. And, in addition to simply presenting and solving problems, the jQuery Cookbook also goes into good depth about the jQuery API and covers broader topics like custom event and plugin creation, theming, and unit testing.

That said, I do have one issue with the book. Well, not so much with the book itself, but rather with the title. It's called a "Cookbook," but the content goes beyond that. It seemed more like 50% cookbook, 50% reference manual, and 10% external resource listing (I'm a doctor Jim - not a mathematician!). In fact, I felt at points that trying to fit the content into a "cookbook" style presentation ended up being a bit awkward.

If you are not familiar with how cookbooks are organized, they are delivered as a bit of background info and a series of units consisting of Problem, Solution, and Discussion. In order to fit the content into this style, I swear there were a few units that were not much more than, "Problem; You need to use the each() method. Solution: Use the each() method." A number of times, I just got the impression that the authors first decided what part of the API they wanted to discuss, and then, as a secondary action, came up with a problem that would allow them to discuss said API.

Furthermore, I thought it was odd that the jQuery Cookbook explored existing plugins. As a cookbook, it seemed odd to present existing solutions as solutions to the given problems. Something about a cookbook style just makes me want to see everything built from scratch, but that's just an emotional reaction.

To be honest, I feel somewhat awkward telling you about my aforementioned issues because they are not related to the quality of the book's content. In fact, if the book was renamed to be something like, "Exploring jQuery," none of the above would have occurred to me at all. I think my problem is that the term "Cookbook" painted a picture in my head, and the picture that I saw in the book didn't quite match. And, in all fairness, I do believe that some of the content would have flowed better had it not been squeezed into a Problem / Solution / Discussion format.

That said, the jQuery Cookbook has some really excellent content and I highly recommend it. In fact, the jQuery Cookbook goes into more depth on certain topics than any of the other jQuery books that I've read so far.




Reader Comments

Dec 14, 2009 at 8:31 AM // reply »
2 Comments

Thanks for the review. I think i will buy the book. I love jQuery and I really want to learn more about that awesome library.
Nice "Friends"-quote by the way ;)


Dec 14, 2009 at 8:34 AM // reply »
11,243 Comments

@Timo,

I think you'll be very happy with the book. Not only does it give you goo jQuery knowledge, it makes you think about it in the context of real world problems, which is very important.


Dec 14, 2009 at 10:02 AM // reply »
7 Comments

Sounds like a good book to keep handy.

Nice pic by the way I like the goatee, very cool ;)


Dec 14, 2009 at 10:04 AM // reply »
11,243 Comments

@Katie,

Thanks - it's finally starting to be bearable and not insanely itchy :) I figured I'd try it out for a while, see what it's like.


Dec 14, 2009 at 10:48 AM // reply »
7 Comments

I really really hate itchy goatee's :)

I say, if the itching is over, then you should definitely keep it.


Dec 14, 2009 at 11:12 AM // reply »
44 Comments

This is a book that's listed on my office's future purchases list. It was good hearing your side of the story. I especially like hearing criticisms as all too many times the Amazon reviewers can be too nice. It really hurts when you get the book and it's not all that it's hyped up to be. Regardless, I will hammer through it once we get it and learn from what I can. Of all the jQuery books to my knowledge, "jQuery in Action" seems to have gotten the most solid reviews so far.


Dec 14, 2009 at 11:39 AM // reply »
11,243 Comments

@Katie,

I'll take that as a compliment ;)

@Jose,

I know what you mean. I try to keep my reviews positive, focusing more on the good stuff; but since my gripes with the book didn't really have anything to do with the quality or usefulness of the content, I felt ok posting it.


Dec 14, 2009 at 12:03 PM // reply »
44 Comments

Thanks, Ben! Now get your review up on Amazon, dangit.


Dec 14, 2009 at 12:07 PM // reply »
7 Comments

Ben -

Like we say in Spanish. Para un buen entendedor. Pocas palabras ;)


Dec 15, 2009 at 6:04 AM // reply »
148 Comments

Thanks for the review! Looking forward to playing more with jQuery. And . . . umm . . . nice goatee . . . it looks great on you!


Dec 15, 2009 at 10:18 PM // reply »
1 Comments

Searching Pdf crack......


Dec 30, 2009 at 8:51 PM // reply »
1 Comments

Hello

I am reading the book, and working with it's recipes, to learn jQuery, I find it very helpful, and awesome.

Altough I am not speaking english well, i can assure anyone that you will never regret to buy it.

Thanks very much.


Dec 31, 2009 at 1:59 PM // reply »
6 Comments

Ben,

Did you get your free copy from o'Reilly that all jQuery Conference attendees were supposed to receive?

Michael from NH


Jan 4, 2010 at 9:43 AM // reply »
11,243 Comments

@Michael,

I did not - I just purchased this one. To get the free copy, I think I was supposed to go onto the O'Reilly website and "Register" using the same email as the conference registration.

But, I wasn't sure what that really meant.


Feb 25, 2010 at 1:23 AM // reply »
1 Comments

This book is great. It's the only book that I have found that goes into unit testing and it covers great ground, with common problems in ths space!



Post A Comment

Comment Etiquette: Please do not post spam. Please keep the comments on-topic. Please do not post unrelated questions or large chunks of code. And, above all, please be nice to each other - we're trying to have a good conversation here.

Please review the following issues:

Author Name:


Author Email:

Author Website:

Comment:

Supported HTML tags for formatting: <strong>bold</strong>   <em>italic</em>   <code>code</code>







  • Help Wanted - Find Your Next ColdFusion Job
Ben Nadel's Company - Epicenter Consulting Recent Blog Comments
May 22, 2013 at 5:35 PM
Script Tags, jQuery, And Html(), Text() And Contents()
This is still an issue 2 years later. jQuery is supposed to remediate these cross browser issues, no? I have been unable to find any statement from the jQuery team calling this behavior "by de ... read »
May 22, 2013 at 12:44 PM
Ask Ben: Query Loop Inside CFScript Tags
In cf10, if you call a function that has: local.result = {}; local.result.msg = ""; local.svc = new query(); local.svc.setSQL("SELECT * FROM..."); local.obj = local.svc.exe ... read »
May 22, 2013 at 12:29 PM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
@Ben: What version of Java are you using? Also, did you test users.id to see what Java reports as the data type? I wonder if it's not a Java primitive data type, but getting returned as something ... read »
May 22, 2013 at 11:47 AM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
@Dana, Awesome - so it looks like this bug was fixed in ColdFusion 10. Thanks so much for double-checking that. ... read »
May 22, 2013 at 11:37 AM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
When I c&p and run on cf10, I get: Selected User IDs: 1,4 User 1 selected: YES - YES User 2 selected: NO - NO User 3 selected: NO - NO User 4 selected: YES - YES User 5 selected: NO - ... read »
May 22, 2013 at 11:27 AM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
@Tom, Good thought, but no dice. Both of these still exhibit the same behavior: users.id[ users.currentRow ] users[ "id" ][ users.currentRow ] It's just something whacky happening with ... read »
May 22, 2013 at 11:07 AM
Strange Interaction Between DeserializeJson(), ArrayContains(), And Database Values In ColdFusion
Could your problem be that "users.id" is actually an ARRAY, not a single value? Perhaps try it again with "users.id[1]" (I only have CF8 here at work). ... read »
May 22, 2013 at 7:52 AM
Nested Views, Routing, And Deep Linking With AngularJS
Hi, Just a quick thank you. As it happens, for my own purposes, the pending ui-router work being done in native angular is likely the one I'll adopt, but your exploration, code and documentation of ... read »
InVision App - Prototyping Made Beautiful With Prototyping Tools