Reputation: 23323
I need to make multiple http calls and don't subscribe to response (let's assume the response is always 204
). Looks like Angular will not make http request if subscription list is empty. How to force it?
Upvotes: 2
Views: 4942
Reputation: 657278
Observables are lazy and don't do anything unless subscribe()
is called.
You don't need to do anything though when data arrives
this.http.get(url).subscribe()
will do.
Upvotes: 11