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
"Attempts to dilucidate which option is more suitable for fast DOM manipulation: jQuery string creation, jQuery DOM manipulation methods or Javascript's documentFragment use."
<script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js" />
<ul id="test-list"></ul>
<script>
var $list = $('#test-list');
var list = $list[0];
</script>
var $list = $('#test-list');
var list = $list[0];
Ready to run.
Test | Ops/sec | |
---|---|---|
jQuery obj + jQuery .append() |
| ready |
createElement + appendChild |
| ready |
jQuery .html() + string concat |
| ready |
innerHTML + string concat |
| ready |
innerHTML + arr |
| ready |
innerHTML + arr |
| ready |
documentFragment + createElement + appendChild + jQuery .html() |
| ready |
documentFragment + createElement + appendChild |
| ready |
You can edit these tests or add more tests to this page by appending /edit to the URL.