jQuery by id vs Document.getElementById

Comparing speed of getting element by id with jQuery vs Vanilla JS
2 years ago
User agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:59.0) Gecko/20100101 Firefox/59.0
Test name Executions per second
jQuery 0.0 Ops/sec
Vanilla JS 3085387.0 Ops/sec
HTML Preparation code:
Tests:
  • jQuery

  • Vanilla JS

Open this result on MeasureThat.net