Run details:
Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko
IE 11
Windows
Desktop
5 years ago
Test name Executions per second
Using each (jQuery) 82061.1 Ops/sec
Using find (jQuery) 41086.0 Ops/sec
Search inside an Array of Strings (Vanilla JS) 4901080.0 Ops/sec
Search inside a HashMap of Strings (Vanilla JS) 4102965.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)


;