Speed comparison of latest jQuery versions 1.6-2.1 (v94)

Revision 94 of this benchmark created on


Description

3.0.0 1.7.2 1.8.3 1.9.1 1.10.2 1.11.3 2.0.3 2.1.4

Preparation HTML

<div>
  <ul id="menu">
    <li class="menu-item">
    </li>
    <li class="menu-item">
    </li>
    <li class="menu-item">
    </li>
    <li class="menu-item">
    </li>
    <li class="menu-item">
    </li>
    <li class="menu-item">
    </li>
  </ul>
</div>
<script type="text/javascript" src="//code.jquery.com/jquery-3.0.0-alpha1.js">
</script>
<script>
  var $jq16 = $.noConflict(true);
</script>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js">
</script>
<script>
  var $jq17 = $.noConflict(true);
</script>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js">
</script>
<script>
  var $jq18 = $.noConflict(true);
</script>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js">
</script>
<script>
  var $jq19 = $.noConflict(true);
</script>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js">
</script>
<script>
  var $jq110 = $.noConflict(true);
</script>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js">
</script>
<script>
  var $jq111 = $.noConflict(true);
</script>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js">
</script>
<script>
  var $jq20 = $.noConflict(true);
</script>
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js">
</script>
<script>
  var $jq21 = $.noConflict(true);
</script>

Setup

function tests($) {
      $('#menu').append("<div class='myclass1'>1</div>");
      $('.myclass1').remove();
    }

Test runner

Ready to run.

Testing in
TestOps/sec
jQuery 3.0.0
tests($jq16);
ready
jQuery 1.7.2
tests($jq17);
ready
jQuery 1.8.3
tests($jq18);
ready
jQuery 1.9.1
tests($jq19);
ready
jQuery 1.10.2
tests($jq110);
ready
jQuery 1.11.3
tests($jq111);
ready
jQuery 2.0.3
tests($jq20);
ready
jQuery 2.1.4
tests($jq21);
ready

Revisions

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