Check if div exists (v3)

Revision 3 of this benchmark created by Eli Perelman on


Preparation HTML

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<div class="a"></div>

Setup

var a = $('.a');

Test runner

Ready to run.

Testing in
TestOps/sec
Property Lookup
a[0]
ready
.length
a.length
ready
.size()
a.size()
ready

Revisions

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