Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36
Chrome 106
Mac OS X 10.14.6
Desktop
2 years ago
Test name Executions per second
offsetWidth / offsetHeight (destructured and renamed) 424429.8 Ops/sec
offsetWidth / offsetHeight (destructured) 436651.7 Ops/sec
offsetWidth / offsetHeight (simple property access) 425812.7 Ops/sec
getBoundingClientRect() (destructured) 492944.4 Ops/sec
getBoundingClientRect() (simple property access) 488658.5 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • offsetWidth / offsetHeight (destructured and renamed)

  • offsetWidth / offsetHeight (destructured)

  • offsetWidth / offsetHeight (simple property access)

  • getBoundingClientRect() (destructured)

  • getBoundingClientRect() (simple property access)