getElementById VS jQuery('#id') (v136)

Revision 136 of this benchmark created on


Preparation HTML

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<div id="foo">
  Test
</div>

Test runner

Ready to run.

Testing in
TestOps/sec
jQuery
jQuery('#foo')
ready
document.getElementById
document.getElementById('foo')
ready
jQuery(document.getElementById())
jQuery(document.getElementById('foo'))
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.