|Pro jQuery 2.0|
Author: Adam Freeman
This weighty tome is written by an enthusiast. Is it going to work for you?
This is essentially a second edition of Pro jQuery brought up-to-date with few changes.
The opening chapter of this brick of a book starts off by admitting that jQuery sounds pretty dull. What jQuery does is to let you modify the contents of HTML documents by manipulating the document model that the browser creates when it processes the HTML. However, Adam Freeman goes on to claim that jQuery makes DOM manipulation a pleasure and, on occasion, an actual joy.
Now most of us around the I Programmer offices have our own particular pet computing obsessions - no-one accidentally opens a conversation with Mike James about artificial intelligence and the further reaches of maths, you definitely don’t want to get Janet Swift started on spreadsheets and VBA, and people have been known to throw things at me when I start talking about databases, so we do understand the pleasure that you can get from programming, but at first glance "joy" seems a bit unlikely in this context.
On the other hand, anything that takes an area of web development that is usually hard work and tedious, and makes it simple, quicker and easier has got to be worth exploring, and it’s usually better to learn from an enthusiast.
The book covers jQuery itself, along with jQuery UI and jQuery Mobile, the two user interface libraries that provide extra features that you can use with jQuery for standard desktop web apps and for those for use on touchscreen mobile devices.
One nice touch is that the main chapters start with a chapter summary in the form of a table showing problems, their solutions, and which listing in the chapter shows the solution. This saves a lot of time when you’re trying to flick through to find the technique you’re stuck with. Freeman’s writing style is good, and I think he could have had a bit more background chat to balance the heavy use of code and tables. On the other hand, as the book is already perilously close to 1000 pages long, I do see the problem this would cause.
Part 4 of the book looks at using jQuery UI, and having gone through setting up jQuery UI, the chapters in this part take the various widgets in turn - the button, progress bar and sliders, autocomplete and accordion, tabs, datepicker and dialog. Freeman shows how to use drag and drop interactions, then the sortable, selectable and resizeable interactions, and how they can all be used to set up rich user interfaces in your HTML code.
jQuery Mobile gives you a way to interact with touch-enabled devices. This, as Freeman says with excellent understatement, provides unique challenges for web application developers. Some elements look as though they’d be fairly straightforward to code; others less so. For example, touch events and their significance have to be interpreted by you, which Freeman says is a painful task fraught with errors and one that he recommends you avoid wherever possible. Fortunately, in a later section he shows the alternative method of using Mobile Gesture methods. This chapter also has a good section on how not to write apps for mobile devices, and what the problems and pitfalls are. Other chapters cover pages and navigation; dialogs, themes, and layouts; buttons and collapsible blocks; mobile forms and lists.
The final part of the book covers advanced features such as the utility methods for handling queues and arrays. There’s a chapter on UI effects and the CSS Framework, and another on using deferred objects.
I didn’t come out of the book with joy uppermost as an emotion, but I can well imagine being very grateful for the techniques shown and the time and effort they’ll save.
|Last Updated ( Monday, 14 April 2014 )|