Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36
Chrome 110
Windows
Desktop
one year ago
Test name Executions per second
Object.hasOwnProperty 9952677.0 Ops/sec
Object in 9099473.0 Ops/sec
Array.indexOf 1627331.2 Ops/sec
direct 9153260.0 Ops/sec
Array includes 1625916.6 Ops/sec
Object.prototype.hasOwnProperty.call(this.storeIndex, index) 5937811.0 Ops/sec
Reflect.has() 4868951.5 Ops/sec
Script Preparation code:
Tests:
  • Object.hasOwnProperty

  • Object in

  • Array.indexOf

  • direct

  • Array includes

  • Object.prototype.hasOwnProperty.call(this.storeIndex, index)

  • Reflect.has()


;