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
const availableGroups = Array.from(Array(120)).map((v, i) => `Test${i + 1}`);
const userGroups = Array.from(Array(20)).map((v, i) => availableGroups[i])
const contacts = Array.from(Array(1000)).map((v,i) => {
const shuffledArray = availableGroups.sort((a, b) => 0.5 - Math.random());
return ({
name: `Contact ${i + 1}`,
groups: Array.from(Array(Math.max(Math.floor(Math.random() * shuffledArray.length / 2), 1))).map((v, i) => shuffledArray[i])
});
})
Ready to run.
Test | Ops/sec | |
---|---|---|
For-Loop with Set |
| ready |
Array.some |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.