Closed jayzyaj closed 5 years ago
The way I achieved this in our project (we are using Ionic 3.x by the way) was to check the API speed using a timer in an interceptor. Depending on how long the request lasts per request is our latency for that particular request lifecycle.
This is not possible with the plugin
My guess is that the only way to measure that is to make an actual request.
Note the time, make a request to a server endpoint that also returns the time, note the time when the response comes in - use all 3 measurement to do some calc for the roundtrip time. (Alternatively connect to any endpoint, do the calc with just 2 numbers)