We\'ve got a single page app built with Knockout and Backbone which makes Ajax calls to the server and does some complex data caching and DOM rendering. We\'re really like t
There are two ways to do it
Lets see the differences between them.
Browsers add supports for Resource Timing API recently. Resource Timing API basically has timing information about each and every resources loaded from app. It may be css, javascript or AJAX requests. You can get list of resources details as
performance.getEntriesByType('resource');
It will return array of object where you can find AJAX requests by initiatorType which is equal to xmlhttprequest. But there are some limitation.
performance.setResourceTimingBufferSize(500). If you can wrap your XMLHTTPRequest API, you will get all information that you need from timing, status code and byte size. But you have to write lot of code and ofcourse test, test and test.
[Disclaimer] I work for atatus.com where we help you to measure page load time, AJAX timing and custom transaction. Also you can see session traces about how each and every resources perform.