qwery vs jquery vs mootools selector engines (v65)

Revision 65 of this benchmark created by asdf asdf on


Description

a simple comparison between different selector engines

Preparation HTML

<script src="https://ajax.googleapis.com/ajax/libs/mootools/1.4/mootools-yui-compressed.js">
</script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js">
</script>
<script>
  jQuery.noConflict();
</script>
<script src="https://raw.githubusercontent.com/ded/qwery/master/src/qwery.js">
</script>
<script src="https://raw.github.com/madrobby/zepto/master/src/zepto.js">
</script>
<script src="https://raw.github.com/chjj/zest/master/lib/zest.js">
</script>
<script src="https://raw.githubusercontent.com/jquery/sizzle/master/dist/sizzle.js">
</script>


<div style="position: relative; width: 100%">
<center>
<div class="navbar">
<a class="barlink" href="http://www.sublimetext.com/">Home</a>
<a class="barlink" href="http://www.sublimetext.com/2">Download</a>
<a class="barlink" href="https://www.sublimetext.com/buy">Buy</a>
<a class="barlink" href="http://www.sublimetext.com/blog/">Blog</a>
<a class="barlink" href="http://www.sublimetext.com/forum/">Forum</a>
<a class="barlink" href="http://www.sublimetext.com/support">Support</a>
</div>

<div style="width: 960px">
        <h1><span class="title1">Sublime</span> Text</h1>

        <p style="font-size: 16px; width: 650px; margin-top: 0px">Sublime Text is a sophisticated text editor for code, markup and prose.<br>You'll love the slick user interface, extraordinary features and amazing performance.</p>
</div>
<div class="band">
        <div id="anim_shell">
                <div id="anim_top"></div>
                <div id="anim_container">
                <div id="anim_left" style="float:left"></div>
                <div id="anim_right" style="float:right"></div>
                <canvas id="target" width="800" height="450">
                <div id="fallback" style="width: 800px; height: 450px; position: relative;"></div>
                </canvas>
                <div id="anim_overlay"></div>
                </div>
                <div id="anim_bottom"></div>
        </div>
        <div class="anim_caption">
                <div class="controls">
                        <a href="javascript:prev()" class="skip"></a> &nbsp; <span id="content_index">2 / 6</span> &nbsp; <a href="javascript:next()" class="skip"></a>
                </div>

                <div id="content">
                <div style="display: none;" id="content1">Use Multiple Selections to rename variables quickly.<br>Here <span class="pc key">Ctrl+D</span><span class="mac key">⌘D</span> is used to select the next occurrence of the current word.</div>

                <div id="content2" style="display: block;">Make batch edits with Multiple Selections.<br>Here <span class="pc key">Ctrl+Shift+L</span><span class="mac key">⇧⌘L</span> is used to split a selection into lines, and each line is then edited simultaneously.</div>

                <div id="content3" style="display: none">The Command Palette gives fast access to functionality.<br>Here <span class="pc key">Ctrl+Shift+P</span><span class="mac key">⇧⌘P</span> is used to show the Command Palette, "sspy" (short for Set Syntax: Python) is used set the syntax of the current file to Python.</div>

                <div id="content4" style="display: none">Use Goto Anything to quickly navigate between files, even in the largest projects.<br><span class="pc key">Ctrl+P</span><span class="mac key">⌘P</span> shows Goto Anything, and typing then filters on file and directory names.</div>

                <div id="content5" style="display: none">Goto Anything can also be used to show a function, line or word within a file.<br>Type @ after a file name to filter on symbols. <a href="http://www.sublimetext.com/blog/articles/sublime-text-2-public-alpha">More...</a></div>

                <div id="content6" style="display: none">Find and Replace with regular expressions.<br>Here unwanted whitespace is removed by using the regex " +" to find groups of spaces, which are then selected simultaneously with the Find All button.</div>
                </div>
        </div>
</div>

<div class="download_bar">
        <div id="download-container">

        <div id="download">
        <span class="win show_32"><a href="http://c758482.r82.cf2.rackcdn.com/Sublime Text 2.0.2 Setup.exe">Download for Windows</a></span>
        <span class="win show_64"><a href="http://c758482.r82.cf2.rackcdn.com/Sublime Text 2.0.2 x64 Setup.exe">Download for Windows</a></span>
        <span class="linux show_32"><a href="http://c758482.r82.cf2.rackcdn.com/Sublime Text 2.0.2.tar.bz2">Download for Linux</a></span>
        <span class="linux show_64"><a href="http://c758482.r82.cf2.rackcdn.com/Sublime Text 2.0.2 x64.tar.bz2">Download for Linux</a></span>
        <span class="mac"><a href="http://c758482.r82.cf2.rackcdn.com/Sublime Text 2.0.2.dmg">Download for OS X</a></span>
        </div>
        <p style="margin: 4px 0 0 0;">
        Version 2.0.2<span class="show_64">, 64 bit</span><span class="linux show_32">, 32 bit</span>

        </p><div id="download-extra" class="extra-bubble">
        <p style="font-size: 11pt">Sublime Text may be downloaded and evaluated for free, however a license must be purchased for continued use. There is no enforced time limit for the evaluation.
        </p><p><a href="/2">Other Platforms</a>
        </p><p><a href="/3">Sublime Text 3 Beta</a>
                </p><div class="extra-bubble-arrow-border"></div>
                <div class="extra-bubble-arrow"></div>
        </div>
        </div>
</div>

<div class="features_band">
        <div style="width: 800px; text-align: left; overflow: hidden;">
        <h2>Some things users love about Sublime Text</h2>
        <div class="section odd">
                <h3>Goto Anything</h3>

                <p>Use Goto Anything to open files with only a few keystrokes, and instantly jump to symbols, lines or words.

                </p><p>Triggered with <span class="pc key">Ctrl+P</span><span class="mac key">⌘P</span>, it is possible to:

                </p><ul>
                    <li>Type part of a file name to open it.
                    </li><li>Type <code>@</code> to jump to symbols, <code>#</code> to search within the file, and <code>:</code> to go to a line number.
                </li></ul>

                <p>These shortcuts can be combined, so <code>tp@rf</code> may take you to a function <em>read_file</em> within a file <em>text_parser.py</em>. Similarly, <code>tp:100</code> would take you to line 100 of the same file.</p>
        </div>

        <div class="section even">
                <h3>Multiple Selections</h3>

                <p>Make ten changes at the same time, not one change ten times. Multiple selections allow you to interactively change many lines at once, rename variables with ease, and manipulate files faster than ever.

                </p><p>Try pressing <span class="pc key">Ctrl+Shift+L</span><span class="mac key">⇧⌘L</span> to split the selection into lines and <span class="pc key">Ctrl+D</span><span class="mac key">⌘D</span> to select the next occurrence of the selected word. To make multiple selections with the mouse, take a look at the <a href="http://www.sublimetext.com/docs/2/column_selection.html">Column Selection</a> documentation.
        </p></div>

        <div class="section odd">
                <h3>Command Palette</h3>

                <p>The Command Palette holds infrequently used functionality, like sorting, changing the syntax and changing the indentation settings. With just a few keystrokes, you can search for what you want, without ever having to navigate through the menus or remember obscure key bindings.

                </p><p>Show the Command Palette with <span class="pc key">Ctrl+Shift+P</span><span class="mac key">⌘⇧P</span>.
        </p></div>

        <div class="section even">
                <h3>Distraction Free Mode</h3>

                <p>When you need to focus, Distraction Free Mode is there to help you out. Distraction Free Mode is full screen, chrome free editing, with nothing but your text in the center of the screen. You can incrementally show elements of the UI, such as tabs and the find panel, as you need them.

                </p><p>You can enter Distraction Free Mode using the <span class="menu">View/Enter Distraction Free Mode</span> menu.
        </p></div>

        <div class="section odd">
                <h3>Split Editing</h3>

                <p>Get the most out of your wide screen monitor with split editing support. Edit files side by side, or edit two locations in the one file. You can edit with as many rows and columns as you wish.

                </p><p>Take advantage of multiple monitors by editing with multiple windows, and using multiple splits in each window.

                </p><p>Take a look at the <span class="menu">View/Layout</span> menu for split editing options. To open multiple views into the one file, use the <span class="menu">File/New View into File</span> menu item.
        </p></div>

        <div class="section even">
                <h3>Instant Project Switch</h3>

                <p>Projects in Sublime Text capture the full contents of the workspace, including modified and unsaved files. You can switch between projects in a manner similar to Goto Anything, and the switch is instant, with no save prompts - all your modifications will be restored next time the project is opened.
        </p></div>

        <div class="section even">
                <h3>Plugin API</h3>

                <p>Sublime Text has a powerful, Python based plugin <a href="http://www.sublimetext.com/docs/2/api_reference.html">API</a>. Along with the API, it comes with a built in Python console to interactively experiment in real time.
        </p></div>

        <div class="section odd">
                <h3>Customize Anything</h3>

                <p>Key Bindings, Menus, Snippets, Macros, Completions and more - just about everything in Sublime Text is customizable with simple JSON files. This system gives you flexibility as settings can be specified on a per-file type and per-project basis.
        </p></div>

        <div class="section even">
                <h3>Cross Platform</h3>

                <p>Sublime Text is available for OS X, Windows and Linux. One license is all you need to use Sublime Text on every computer you own, no matter what operating system it uses.

                </p><p>Sublime Text uses a custom UI toolkit, optimized for speed and beauty, while taking advantage of native functionality on each platform.
        </p></div>
        </div>
</div>

<center>
<div style="width: 900px; padding-top: 2ex;">
<img src="images/apple_48.png" style="margin: 4px" height="48" width="39">
<img src="images/windows_48.png" style="margin: 4px; margin-left: 9px" height="45" width="48">
<img src="images/linux_48.png" style="margin: 4px" height="48" width="41">
</div>
<p style="font-size: 10pt">Sublime Text is available for OS X, Windows and Linux.
</p></center>

</center>
</div>

Test runner

Ready to run.

Testing in
TestOps/sec
Slick.find
Slick.find(document, ".features_band .section .mac.key");
ready
Slick.search
Slick.search(document, ".features_band .section .mac.key");
ready
jQuery
jQuery(".features_band .section .mac.key");
ready
qwery
qwery(".features_band .section .mac.key");
ready
zepto
Zepto(".features_band .section .mac.key");
ready
Zest
zest(".features_band .section .mac.key");
ready
Sizzle
Sizzle(".features_band .section .mac.key");
ready
querySelector
document.querySelector(".features_band .section .mac.key")
ready

Revisions

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