Run details:
Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.100 Safari/537.36
Chrome 76
Windows 7
Desktop
4 years ago
Test name Executions per second
Object.hasOwnProperty 3365969.0 Ops/sec
Object in 2574465.2 Ops/sec
Array.indexOf 776216.6 Ops/sec
direct 3152999.8 Ops/sec
Array includes 775831.2 Ops/sec
Script Preparation code:
Tests:
  • Object.hasOwnProperty

  • Object in

  • Array.indexOf

  • direct

  • Array includes