Skip to content

Instantly share code, notes, and snippets.

@donaldpipowitch
Created August 21, 2019 13:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save donaldpipowitch/1a7897a9bd630d8ee8a47ae83c7fb883 to your computer and use it in GitHub Desktop.
Save donaldpipowitch/1a7897a9bd630d8ee8a47ae83c7fb883 to your computer and use it in GitHub Desktop.
Subsequent requests with RxJS (and Angular), but using the first response
this.http.get<Data1>(url1).pipe(
mergeMap((data1) =>
this.http.get<Data2>(url2).pipe(map((_data2) => data1))
)
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment