Zepto 1.0.1 vs jQuery 2.0.3 - 2013-08-08 (v9)

Revision 9 of this benchmark created on


Description

Comparison of latest (as of 2013-08-08) versions of Zepto and jQuery 2.x

Preparation HTML

<div id="container"></div>
<script src="//zeptojs.com/zepto.min.js"></script>
<script src="//code.jquery.com/jquery-2.0.3.js"></script>

Setup

//Lets add the append method to all html dom nodes:
    HTMLElement.prototype.append = function(el) {
      this.appendChild(el);
    }
    
    var container = document.getElementById('container');
    var ul, li, i = 0;

Teardown


    container.innerHTML = "";
  

Test runner

Ready to run.

Testing in
TestOps/sec
Zepto
ul = Zepto("<ul/>");
for (; i < 100; i += 1) {
  li = Zepto("<li>hello world</li>");
  ul.append(li);
}
Zepto(container).append(ul);
ready
jQuery
ul = jQuery("<ul/>");
for (; i < 100; i += 1) {
  li = jQuery("<li>hello world</li>");
  ul.append(li);
}
jQuery(container).append(ul);
ready

Revisions

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