jQuery vs dollar sign (v2)

Revision 2 of this benchmark created by Eroan on


Description

A test to see if with the jQuery library, its faster to use the alias dollar sign ($) or using jQuery directly.

Preparation HTML

<script src="//code.jquery.com/jquery-2.1.3.min.js"></script>

Test runner

Ready to run.

Testing in
TestOps/sec
Using dollar sign
$('<div>test</div>');
ready
Using jQuery
jQuery('<div>test</div>');
ready

Revisions

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

  • Revision 1: published by Tyler on
  • Revision 2: published by Eroan on