Run details:
Mozilla/5.0 (Linux; Android 9; SAMSUNG SM-G960F) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/11.1 Chrome/75.0.3770.143 Mobile Safari/537.36
Chrome Mobile 75
Android
Mobile
4 years ago
Test name Executions per second
Switch 555174.2 Ops/sec
If (else) 566667.0 Ops/sec
Object selector 763098.6 Ops/sec
Script Preparation code:
Tests:
  • Switch

  • If (else)

  • Object selector