Performance Test

Problem & Test Overview

We need to compare the runtime performance of three different ways to access object properties in a large dataset of JavaScript objects. Each object contains 100 fields named in `snake_case`. The three approaches are:

  1. Direct snake_case access - accessing properties by their original snake_case keys (e.g. obj['first_name']).
  2. Pre-converted camelCase access - before running the tests, all snake_case fields are converted once to camelCase and the objects overwritten accordingly; access then uses the new camelCase keys (e.g. obj['firstName']).
  3. Proxy wrapper - wrapping each object in a Proxy that intercepts property lookups and transparently maps camelCase accessors to the underlying snake_case fields.

Loading datasets...