Kimbo vs jQuery vs BSI each
JavaScript performance comparison
Preparation code
<script src="http://kimbojs.com/lib/kimbo.js"></script>
<script src="http://code.jquery.com/jquery-git2.js"></script>
<script src="http://bytes1.dyndns.org/BSI/website-app.js"></script>
<div id="header">
<h1>
Test
</h1>
<nav>
<ul class="menu">
<li class="button">
One
</li>
<li class="button">
Two
</li>
<li class="button">
Three
</li>
</ul>
</nav>
</div>
<div id="container">
<h2>
Test 2
</h2>
<p>
Lorem
</p>
<ul id="list" class="menu">
<li>
Item 1
</li>
<li>
Item 2
</li>
<li>
Item 3
</li>
</ul>
<form>
<input name="name" placeholder="name" />
</form>
</div>
<div id="footer">
<p>
Footer
</p>
</div>
<script>
window.$k = Kimbo;
window.$j = jQuery;
window.$b = BSI.tag;
</script>
<script>
Benchmark.prototype.setup = function() {
var $kli = $k('li'), $li = $('li'), $bli = $b('li');
};
</script>
Preparation code output
<div id="header">
<h1>
Test
</h1>
<nav>
<ul class="menu">
<li class="button">
One
</li>
<li class="button">
Two
</li>
<li class="button">
Three
</li>
</ul>
</nav>
</div>
<div id="container">
<h2>
Test 2
</h2>
<p>
Lorem
</p>
<ul id="list" class="menu">
<li>
Item 1
</li>
<li>
Item 2
</li>
<li>
Item 3
</li>
</ul>
<form>
<input name="name" placeholder="name" />
</form>
</div>
<div id="footer">
<p>
Footer
</p>
</div>
Test runner
Warning! For accurate results, please disable Firebug before running the tests. (Why?)
Java applet disabled.
Test | Ops/sec | |
---|---|---|
Kimbo .each()
|
|
pending… |
jQuery .each()
|
|
pending… |
BSI.forEach()
|
|
pending… |
BSI.NL.forEach()
|
|
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.
- Revision 1: published Denis
- Revision 2: published Rick Waldron
- Revision 3: published
- Revision 4: published Denis
- Revision 5: published
0 Comments