Learning jQuery Deferreds: Taming Callback Hell with Deferreds and Promises

·
· "O'Reilly Media, Inc."
Ebook
132
Pages
Eligible

About this ebook

Orchestrating asynchronous function calls in JavaScript often leads to callback hell, but there is a reliable way to avoid this painful state of affairs. With this concise and simple guide, you’ll learn how to use jQuery deferreds and promises, an elegant approach for managing asynchronous calls in both client and server applications.

This book contains 18 examples that use deferreds to solve progressively challenging real-world programming problems, along with 75 stimulating puzzles (and their solutions) that will help you understand how and when to use deferreds. Experienced JavaScript programmers will learn new tricks in a fun way, and become immersed in the practice of event-based programming.

  • Understand the logic behind creating deferreds and returning promises
  • Get a structured explanation of jQuery’s deferred API
  • Delve into the dynamics of using deferreds
  • Explore a broad collection of useful deferred recipes developed by the authors
  • Gain hands-on experience by solving challenges that accompany each recipe
  • Go deeper into deferreds: encounter novel abstractions and mind-bending use cases

Discover more

About the author

Terry Jones is currently CTO of Fluidinfo, which he founded in 2007. He also works on virus discovery in the Zoology department at the University of Cambridge. Before founding Fluidinfo, he was a postdoc in Zoology at Cambridge (2004-07) where he spent time helping the WHO design part of the human influenza vaccine. He was a part-time professor in CS at the Universitat de Pompeu Fabra in Barcelona (2005-06), CTO of Eatoni Ergonomics in New York (2000-04), a postdoc in Cognitive Science at UCSD (1998-99), CEO of Teclata in Barcelona (1996-98), Chief Knowledge Officer at Chiliad (1998), a postdoc and graduate fellow at the Santa Fe Institute (1992-96), and taught undergrad CS at Earlham College (1990-91). He has a Ph.D. in CS from the University of New Mexico, an M.Math from the University of Waterloo, and a B.Sc. in CS from Sydney University.

Rate this ebook

Tell us what you think.

Reading information

Smartphones and tablets
Install the Google Play Books app for Android and iPad/iPhone. It syncs automatically with your account and allows you to read online or offline wherever you are.
Laptops and computers
You can listen to audiobooks purchased on Google Play using your computer's web browser.
eReaders and other devices
To read on e-ink devices like Kobo eReaders, you'll need to download a file and transfer it to your device. Follow the detailed Help Center instructions to transfer the files to supported eReaders.