Run details:
Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:89.0) Gecko/20100101 Firefox/89.0
Firefox 89
Ubuntu
Desktop
3 years ago
Test name Executions per second
Pure JS ID Selector 44020.6 Ops/sec
Pure JS Class Selector 44379.2 Ops/sec
Pure JS Data Hook 35984.3 Ops/sec
jQuery ID Selector 40258.4 Ops/sec
jQuery Class Selector 34070.2 Ops/sec
jQuery Data Hook Selector 30679.8 Ops/sec
HTML Preparation code:
Tests:
  • Pure JS ID Selector

  • Pure JS Class Selector

  • Pure JS Data Hook

  • jQuery ID Selector

  • jQuery Class Selector

  • jQuery Data Hook Selector


;