Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/111.0
Firefox 111
Windows
Desktop
2 years ago
Test name Executions per second
Object.hasOwn 864778816.0 Ops/sec
in 866545664.0 Ops/sec
Script Preparation code:
AخA
 
obj = {a: 42, b:66, c: 88}
Tests:
  • Object.hasOwn

     
    Object.hasOwn(obj, 'b')
  • in

     
    'b' in obj