Learning the Yahoo! User Interface Library

An important part of my recent project is an interactive web based user interface that meets the latest usability requirements and technology. Therefore I have to use DHTML, JavaScript, HTML and CSS. Because of the different behavior of current web browsers I decided to use one of the existing JavaScript libraries. After evaluating several of them I decided to go with the Yahoo! User Interface (YUI) library. Even if the YUI online documentation is brilliant and reading the YUI source code is relatively easy, I like to read a book as well. This post outlines my experience with the recently published book: “Learning the Yahoo! User Interface Library” by Dan Wellman.

The book is structured into a short introduction to YUI, and several chapters each covering the different utilities and controls of the library. The structure of the chapters is always quite similar. First there is a detailed explanation of the component and for what it might be used. Later in the chapter the power of the utility or control is demonstrated on a good  example which he describes very detailed. Dan did a very good job on selecting practical examples that find the balance between being not too simple, but on the other hand are not too complex to follow.

You will find examples for almost all YUI controls like with calendar, button, tree view, auto complete but also utilities like animation, connection manager and browser history manager. Unfortunately Dan did not cover any beta widgets in his book. I understand his decision, but there are some very interesting beta components in the YUI library like the rich text editor, resize and data table. I know that the APIs of the beta components are not stable and may change, but he could have added a chapter covering some of the most interesting beta development.

In the book Dan mentions that he assumes that the reader of the book already knows JavaScript, HTML and CSS. You don’t find any section in the book teaching you about the JavaScript language or the other technologies. Therefore if you are new to JavaScript and the YUI library you need an additional source to learn JavaScript. Unfortunately there is no good book out there that I can recommend. Maybe the new book from Douglas Crockford, “JavaScript: The Good Parts” is the JavaScript learning book everyone already has waited for.

Conclusion: Dan did an excellent job explaining the YUI library on very practical examples. If you plan to use the YUI library for one of your projects, I can recommend this book as an addition to the excellent YUI online documentation. But this book requires that you already know JavaScript, or that you learn JavaScript from a different source.

Leave a Reply