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="//rawgit.com/CrossEye/ramda/master/ramda.js"></script>
function newFind(fn, list) {
function _find(list) {
var idx = -1;
var len = list.length;
while (++idx < len) {
if (fn(list[idx])) {
return list[idx];
}
}
return undef;
}
return arguments.length < 2 ? _find : _find(list);
}
list = [1,7,3,9,2003,30415,262,10120,10403,123, 563, 6, 2002, 20020];
function pred(x) { return x > 100 && x % 2 === 0; }
Ready to run.
Test | Ops/sec | |
---|---|---|
ramda.find |
| ready |
newFind |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.