Run details:
Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.66 Safari/537.36
Chrome 87
Windows 8.1
Desktop
3 years ago
Test name Executions per second
Object-Function 2707087.0 Ops/sec
Object-plain 2618043.0 Ops/sec
If-Else 692713.7 Ops/sec
Ternary 700820.6 Ops/sec
Switch 2634560.0 Ops/sec
Tests:
  • Object-Function

  • Object-plain

  • If-Else

  • Ternary

  • Switch

  • Object-Get


;