Sample Chapter — Pro JavaScript Design Patterns by Ross Harmes and Dustin Diaz
December 17, 2007 at 11:46 am by Eric Miraglia | In Development |
Fellow Yahoo Ross Harmes and former Yahoo (current Googler) Dustin Diaz have collaborated on a new book from Apress, Pro JavaScriptâ„¢ Design Patterns. As the title suggests, this volume focuses on the implementation of common object-oriented design patterns in the JavaScript language. Ross and Dustin “wanted to show programmers that JavaScript contains features on par with other high-level languages and is an object-oriented programming language in its own right.”
Ross, Dustin and their Apress editors were kind enough to let us share a chapter of the book here on YUIBlog:
- Chapter 9: The Flyweight Pattern — “[The Flyweight pattern is] most useful in
situations where large numbers of similar objects are created, causing performance problems. This pattern is especially useful in JavaScript, where complex code can quickly use up all of the available browser memory. By converting many independent objects into a few shared objects, you can reduce the amount of resources needed to run web applications. The benefit of this can vary widely. For large applications that can potentially be used for days at a time without being reloaded, any technique that reduces the amount of memory used can have a very positive effect.”
For more on the design patterns covered in the book and information about where to buy it, check out the jsdesignpatterns.com website. The e-Book version is also available from Apress.
Congratulations to Dustin and Ross on getting this book done and contributing to the growing conversation about the role of design patterns in the JavaScript language.
Share and extend: Bookmark with Yahoo! My Web | Bookmark with del.icio.us | digg it! | reddit!
5 Comments »
RSS feed for comments on this post. TrackBack URI
Leave a comment

Copyright © 2007 Yahoo! Inc. All rights reserved. Privacy Policy - Terms of Service
Powered by WordPress on Yahoo! Web Hosting.
[…] now chapter nine of our book Pro JavaScript Design Patterns is available on the YUI Blog, The Flyweight Pattern. Go ahead and have a look see and check it out. Feel free to leave comments on the YUI Blog […]
Pingback by JS Design Patterns Sample Chapter available on YUI Blog — December 17, 2007 #
I’ve just read the entire chapter.
I found it very interesting because is well written, expecially the final part of the chapter,
with the when design pattern XYZ should be usedgeneral steps for implementing itbenefits and drawbacks of it sections.
If before reading it I had fews concern, now I’ve no more dubt and I really consider to buy it.
BTW, Thanks to share this chapter with us (I just need it).
Comment by kentaromiura — December 19, 2007 #
This is a great book. Some early chapters from Ross really helped me with a huge project this fall, this may be the best javascript book I’ve seen yet.
Comment by Stephen — December 21, 2007 #
Thanks for sharing. It is time to order the book. I hope I learn a lot from the book.
Comment by grayger — December 27, 2007 #
Thanks for sharing a fr.ee chapter, it looks great. I’ve just ordered the book as a result. ;0)
Comment by Lancashire Website Designers — March 17, 2008 #