Skip to content

Instantly share code, notes, and snippets.

@jnizet
Created December 10, 2018 22:31
Show Gist options
  • Select an option

  • Save jnizet/aeb37e62a059c99f2bb43f19d0b82e4a to your computer and use it in GitHub Desktop.

Select an option

Save jnizet/aeb37e62a059c99f2bb43f19d0b82e4a to your computer and use it in GitHub Desktop.
this.firstService.getFirstResults(filterOption).pipe(
mergeMap(firstResult => this.secondService.getSecondResults(firstResult)),
mergeMap(secondResult => this.thirdService.getThirdResults(secondResult))
).subscribe(
thirdResult => this.processResult(thirdResult, filterOption),
null,
() => console.log("COMPLETE")
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment