Run details:
Mozilla/5.0 (Windows NT 6.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.112 Safari/537.36
Chrome 49
Windows Vista
Other
7 years ago
Test name Executions per second
jQuery(jQuery.clone()) 34962.0 Ops/sec
jQuery(jQuery).clone() 38938.4 Ops/sec
jQuery(JavaScript).clone() 44994.5 Ops/sec
jQuery(JavaScript.cloneNode.content) 105427.7 Ops/sec
jQuery(JavaScript.content.cloneNode) 124132.0 Ops/sec
jQuery(getElementById.content.cloneNode) 134002.1 Ops/sec
Pure JavaScript.cloneNode.content 153788.5 Ops/sec
Pure JavaScript.content.cloneNode 188035.3 Ops/sec
HTML Preparation code:
Tests:
  • jQuery(jQuery.clone())

  • jQuery(jQuery).clone()

  • jQuery(JavaScript).clone()

  • jQuery(JavaScript.cloneNode.content)

  • jQuery(JavaScript.content.cloneNode)

  • jQuery(getElementById.content.cloneNode)

  • Pure JavaScript.cloneNode.content

  • Pure JavaScript.content.cloneNode


;