Browser Diet - $(this).attr('id') vs. this.id

JavaScript performance comparison

Revision 13 of this test case created by rage DNA

Preparation code

What's up, its good post about media print, we all be familiar with 
media is a impressive source of facts.
      
<script>
Benchmark.prototype.setup = function() {
  What's up, its good post about media print, we all be familiar with media is a impressive source of facts.

};

Benchmark.prototype.teardown = function() {
  What's up, its good post about media print, we all be 
  familiar with media is a impressive source of facts.

};
</script>

Preparation code output

What's up, its good post about media print, we all be familiar with media is a impressive source of facts.

Test runner

Warning! For accurate results, please disable Firebug before running the tests. (Why?)

Java applet disabled.

Testing in CCBot 2.0.0 / Other 0.0.0
Test Ops/sec
jQuery's .attr()
What's up, its good post about media print, we all be 
familiar with media is a impressive source of facts.
pending…
Pure JavaScript
What's up, its good post about media print, we all be familiar with media is 
a impressive source of facts.
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.

0 Comments

What's up, its good post about media print, we all be familiar with media is a impressive source of facts.