I am trying to improve jQuery's performance, and I noticed that it works faster in Chrome than in other browsers. Does it make sense when it's just an AJAX call to a PHP file?
To test this, I do this in the click event:
var startTime = new Date(); $.post("http://"+ document.domain + "action.json", { data: data}, function(dat){ console.log('ending: ', (new Date() - startTime) / 1000); } });
Result in seconds:
- Chrome 25: 0.148
- Firefox 19.0.2: 0.212
- Internet Explorer 9: 0.272
- Opera 12.14: 0.219
Can development tools for accessing the console in each browser interfere with these results?
Thanks.
Alvaro
source share