how fast does jquery turn a node into an object

Benchmark created on


Preparation HTML

<div id="myid">hello</div>

<script src="//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
 
<script>
  var targetNode = document.getElementById("myid");
  var confirma = undefined;
  var confirmb = undefined;
</script>

Test runner

Ready to run.

Testing in
TestOps/sec
node in already
confirma = $(targetNode);
ready
select it
confirmb = $("#myid");
ready

Revisions

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