If I have a service call that relies on the result of another service call what is the best way to chain them?
myService.getStuffFromServer().subscribe(data => {
let manipulatedData = functionThatManipulatesData(data);
myService.getMoreStuffFromServer(manipulatedData).subscribe(moreData => {
doStuffWithMoreData(moreData);
});
});
Is the way I have been doing it but the nesting gets a bit messy sometimes. Is there a cleaner way?