css (v16)

Revision 16 of this benchmark created on


Preparation HTML

<div id="foo" style="border: 1px solid blue" class="asd sdf dfg">I am a DIV</div>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>

Test runner

Ready to run.

Testing in
TestOps/sec
get css
$('#foo').css('display');
ready
set css
$('#foo').css('display','block');
ready
.is(":visible")
$('#foo').is(":visible")
ready
hasClass("crap")
$('#foo').hasClass("crap")
ready
addClass("crap1")
$('#foo').addClass("crap1")
ready
$('#foo').attr("style","display:block")
$('#foo').attr("style","display:block")
ready

Revisions

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