I'm using jQuery to benchmark the time API Requests take. For this, i'll run the same request repeated in a specific interval. Everything runs just fine.
BUT if I reduce the interval to be significant lower than the time the API Request takes to return, the benchmarked time will add up.
Try to decrease the Interval in the JSBin Example to 100 and you'll see what I mean:
Reduced JSBin Example: http://jsbin.com/azuqUho/4/edit
I've visualized this here:
Since I can't pass the now variable to the success function of getJSON, i'm not sure how to solve this problem.
Any suggestions?
Thanks, Simon