Previously, inside BackendService we used a get and post method to patch the requests made by Angular HttpClient with:
correct withCredentials and Content-Type-Header values
revealing and hiding the progress bar
adding timing to Explore-page requests
To improve extensibility of BackendService, all of these features have been moved to Angular HttpInterceptor services.
ExploreTimingInterceptor
HttpOptionsInterceptor
RequestProgressInterceptor
Additionally, HTTP error responses will now be logged and have their response body swapped with undefined in a new HttpErrorInterceptor.
This was done to prevent having to .catch() errors everywhere in the application and make response data easily awaitable, as data either exists or not, while still receiving error information in the developer console.
Previously, inside
BackendService
we used aget
andpost
method to patch the requests made by AngularHttpClient
with:withCredentials
andContent-Type
-Header valuesTo improve extensibility of
BackendService
, all of these features have been moved to AngularHttpInterceptor
services.ExploreTimingInterceptor
HttpOptionsInterceptor
RequestProgressInterceptor
Additionally, HTTP error responses will now be logged and have their response body swapped with
undefined
in a newHttpErrorInterceptor
. This was done to prevent having to.catch()
errors everywhere in the application and make response data easilyawait
able, as data either exists or not, while still receiving error information in the developer console.