Sizzle vs jQuery (v7)

Revision 7 of this benchmark created by Jean Ducrot on


Preparation HTML

<script src="https://cdnjs.cloudflare.com/ajax/libs/sizzle/2.0.0/sizzle.min.js"></script>
<script src="http://code.jquery.com/jquery-1.8.3.min.js"></script>

<div id='idTest'>
 <ul>
    <li>1</li>
    <li>2</li> 
 </ul>
</div>

Test runner

Ready to run.

Testing in
TestOps/sec
jQuery
$("div");
$("#idTest");
$("ul li")
ready
Sizzle
Sizzle("div");
Sizzle("#idTest");
Sizzle("div ul li")
ready
Native
document.getElementsByTagName("div");
document.querySelectorAll("#idTest");
document.querySelectorAll("div ul li")
ready

Revisions

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