My question is if i have one http observable method and is called two times in one second.The second call will abort the first one automatically? or i have to use unsubscribe on the first http call to stop it, this is to limit the http calls in a google map where i run a http call every time there is a zoom, in mobile can happen that the zoom is zoomed out more than once in a short period of time.
Thanks
getClusters(params) {
if(this.ajaxCall) {
this.ajaxCall.unsubscribe();
}
this.ajaxCall = this.http
.post(`${LOCAL_URL}/getClusters`, params)
.subscribe((response: Response) => {
response.json();
});
return this.ajaxCall;
}