selectors

Benchmark created by evansdiy on


Preparation HTML

<script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>

<div id="foo">
    <p class="bar">Sample Text 1</p>
</div>

<p>Sample Text 2</p>
<p>Sample Text 3</p>
<p>Sample Text 4</p>

Test runner

Ready to run.

Testing in
TestOps/sec
1
$('div#foo p.bar');
ready
2
$('#foo p');
ready
3
$('#foo .bar')
ready
4
$('#foo').find('p');
ready
5
$('#foo').find('.bar');
ready
6
$('#foo').children('p');
ready
7
$('#foo').children('.bar');
ready
8
$('#foo p.bar');
ready

Revisions

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

  • Revision 1: published by evansdiy on