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
Test ever true switch and else if
const doSomething = () => {
const temp = 1 + 2 + 3
return temp
}
const a = 500
const b = 'abc'
const c = {
a: 1,
b: 2,
c: 3
}
const d = {
a: {
aa: 'abc',
ab: {
aba: 'abcdefghijk',
abb: 'abcdefghijk',
abc: 'abcdefghijk',
abd: 'abcdefghijk',
abe: 'abcdefghijk'
}
},
b: {
ba: 'def',
bb: 'abcdefghijkabcdefghijk'
}
}
const e = 'abc'
Ready to run.
Test | Ops/sec | |
---|---|---|
Ever true switch |
| ready |
Else if |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.