Run details:
Mozilla/5.0 (Linux; Android 11; SM-A207F) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.159 Mobile Safari/537.36
Chrome Mobile 92
Android
Mobile
3 years ago
Test name Executions per second
Using each (jQuery) 28611.1 Ops/sec
Using find (jQuery) 18267.1 Ops/sec
Search inside an Array of Strings (Vanilla JS) 287612.1 Ops/sec
Search inside a HashMap of Strings (Vanilla JS) 283465.5 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • Using each (jQuery)

  • Using find (jQuery)

  • Search inside an Array of Strings (Vanilla JS)

  • Search inside a HashMap of Strings (Vanilla JS)


;