I'm wondering if observable or promise can be used in the following use case in angular 2:
There are two asynchronized upload tasks. I'd like to know how I can detect both tasks are finished.
My upload task (implemented in promise but it's easily be changed to observable if needed) is like this:
myService.upload('upload1').then(() => {
})
myService.upload('upload2').then(() => {
})
How to chain these two events together in either promise or observable so that I know both tasks are finished? Thanks