As stated in the introduction of this chapter, we will build upon our JSON API for the Marvel Cinematic Universe of Chapter 7, Asynchronous Programming Using Observables. To be a bit more precise, we will improve the Promise-based version. Why Promises instead of pure observers? Well, Promises are an extremely powerful tool, and they are used in the majority of Angular/Typescript projects I have seen so far. Consequently, a bit more practice with Promises won't hurt much.
You can find the code of the Promises part here http://bit.ly/mastering-angular2-chap7-part3.
To clone this code into a new repo called advanced-forms, use the following command:
$ git clone --depth one https://github.com/MathieuNls/mastering-
angular2 advanced-forms
$ cd advanced-forms
$ git filter-branch --prune-empty --subdirectory-filter chap7/angular-
promise HEAD
$ npm install
These...