jsPerf.app is an online JavaScript performance benchmark test runner & jsperf.com mirror. It is a complete rewrite in homage to the once excellent jsperf.com now with hopefully a more modern & maintainable codebase.
jsperf.com URLs are mirrored at the same path, e.g:
https://jsperf.com/negative-modulo/2
Can be accessed at:
https://jsperf.app/negative-modulo/2
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js"></script>
var largeArray = new Array(10000);
for (var tmpix = 0; tmpix < 10000; tmpix++) {
largeArray[tmpix] = {
a: Math.floor(Math.random() * 10000),
b: 10000 - tmpix,
c: "element" + tmpix
}
}
Ready to run.
Test | Ops/sec | |
---|---|---|
jQuery.grep |
| ready |
Array.filter |
| ready |
jQuery.each |
| ready |
Array.forEach |
| ready |
for loop |
| ready |
grep by for loop and callback |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.