In this section, thought to talk about HTTP-Client usage in angular and how its different from existing HTTP Module. It has RxJS Observable-based API. It means that the multiple calls to the HTTP module will return an observable, which we need to subscribe.
- If we don’t subscribe to these observables, it won’t work.
- If we subscribe multiple times to these observables, multiple HTTP requests will be triggered.
- If HTTP request is successful, it will emit only one value and then complete
- If HTTP request fails, then these observables will emit an error.
1,104 total views, 1 views today