Chapter 4
Advanced Async

BANG! The starting gun goes off as two functions shoot down the track. Firing off AJAX requests willy-nilly, the competing functions zip around corner after corner until finally, one reaches the finish line inches before the other. The functions line up in the winner’s circle as the judge pulls out the envelope. Suddenly, pandemonium erupts when the envelope reveals that the functions weren’t supposed to finish in that order! Disaster!

Fortunately, software development isn’t that exciting (I don’t think I could deal with that every day). Still, functions finishing in the wrong order can spell disaster. In this chapter, you learn how clever Rx use can prevent race conditions before they have a chance to happen. The previous chapters covered areas where observables are helpful, but not transformative. Now you’ll build something where Rx completely changes the development cycle: a typeahead module that makes an AJAX request to grab results.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
13.58.50.156