jQuery Selector Perf - Check different selectors
JavaScript performance comparison
Preparation code
<div id="step1" class="step ">
<div class="instructions">Choose an option in the steps before this one to get a choice</div>
<select id="filter_0" class="filter">
<option value="">--- Select an option ---</option>
<option value="77">Argentinia</option>
<option value="78">Brazil</option>
<option value="79">Chile</option>
<option value="81">Ecuador</option>
<option value="80">Uruguay</option>
</select>
</div>
<div id="step2" class="step ">
<div class="instructions">Choose an option in the steps before this one to get a choice</div>
<select id="filter_77" class="filter">
<option value="">--- Select an option ---</option>
<option value="82">Catamarca</option>
<option value="83">Chaco</option>
<option value="84">Chubut</option>
<option value="85">Córdoba</option>
<option value="86">Corrientes</option>
<option value="87">Entre Ríos</option>
<option value="88">Formosa</option>
</select>
<select id="filter_78" class="filter">
<option value="">--- Select an option ---</option>
<option value="89">Acre</option>
<option value="90">Alagoas</option>
<option value="91">Amapá</option>
<option value="92">Amazonas</option>
</select>
<select id="filter_79" class="filter">
<option value="">--- Select an option ---</option>
<option value="95">Antofagasta</option>
<option value="96">Atacama</option>
<option value="93">Arica and Parinacota</option>
<option value="94">Tarapacá</option>
</select>
<select id="filter_81" class="filter">
<option value="">--- Select an option ---</option>
<option value="97">Azuay</option>
<option value="98">Bolivar</option>
<option value="99">Cañar</option>
</select>
<select id="filter_80" class="filter">
<option value="">--- Select an option ---</option>
<option value="100">Artigas</option>
<option value="101">Canelones</option>
<option value="102">Cerro Largo</option>
</select>
</div>
<div id="step3" class="step ">
<div class="instructions">Choose an option in the steps before this one to get a choice</div>
<select id="filter_82" class="filter">
<option value="">--- Select an option ---</option>
<option value="103">San Fernando</option>
</select>
</div>
<div id="step4" class="step">
<div id="filter_tags" class="filter">
</div>
<div id="filter_hotel" class="filter">
</div>
</div>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
Preparation code output
Choose an option in the steps before this one to get a choice
Choose an option in the steps before this one to get a choice
Choose an option in the steps before this one to get a choice
Test runner
Warning! For accurate results, please disable Firebug before running the tests. (Why?)
Java applet disabled.
| Test | Ops/sec | |
|---|---|---|
Class Selector |
|
pending… |
Tag + class selector |
|
pending… |
.class Selector + limit tag |
|
pending… |
Compare results of other browsers
Revisions
You can edit these tests or add even more tests to this page by appending /edit to the URL. Here’s a list of current revisions for this page:
- Revision 1: published by Jeffrey Way
- Revision 32: published
- Revision 37: published
- Revision 38: published
- Revision 40: published
- Revision 41: published
- Revision 44: published
- Revision 45: published
- Revision 46: published
- Revision 47: published
- Revision 48: published
- Revision 49: published
- Revision 50: published by ShiningRay
- Revision 52: published
- Revision 54: published
- Revision 55: published by tick
- Revision 56: published
- Revision 57: published
- Revision 58: published by MoonScript
- Revision 59: published by richard
- Revision 60: published
- Revision 61: published
- Revision 62: published
- Revision 63: published
- Revision 64: published
- Revision 65: published
- Revision 68: published by m--s
- Revision 69: published by devu
- Revision 70: published by Scott Kosman
- Revision 71: published
- Revision 74: published
- Revision 75: published
- Revision 83: published
- Revision 84: published
- Revision 87: published
- Revision 88: published by Chris Miller
- Revision 89: published by Chris Miller
- Revision 90: published by Chris Miller
- Revision 91: published
- Revision 92: published by Dominik Nejdl
- Revision 93: published
- Revision 94: published
- Revision 95: published by Marco Pfeiffer
- Revision 97: published
- Revision 98: published
- Revision 99: published
- Revision 101: published
- Revision 102: published
- Revision 103: published
- Revision 104: published by BinaryKitten
- Revision 105: published
- Revision 106: published by Reith
- Revision 107: published
- Revision 108: published
- Revision 109: published
- Revision 110: published
- Revision 112: published by Claire
- Revision 113: published by Claire Martinez
- Revision 114: published
- Revision 115: published
0 comments