I want to log the time taken by a $http query to fetch the results. One solution will be calculating the difference of time before and after making the call. So, is there any other better way to know the time taken to fetch the results?
相关问题
- Angular RxJS mergeMap types
- angularJS: ui-router equivalent to $location.searc
- Google Apps Script: testing doPost() with cURL
- How to instantiate Http service in main.ts manuall
- Separate AngularJS Controllers Into Separate Files
You can use an interceptor for $httpProvider
And then you can console.log or you could setup $log, or do what you want with the data.