strucutredClone vs JSON.parse(JSON.stringify())Fastest: JSON.parse(JSON.stringify()) (1.5x faster)
418,168 ops/sec
287,309 ops/sec
Fastest: strucutredClone (1.6x faster)
333,059 ops/sec
213,272 ops/sec
Fastest: JSON.parse(JSON.stringify()) (2.0x faster)
676,022 ops/sec
336,819 ops/sec
Results show median performance across all community submissions. Run this benchmark yourself to verify on your device.
| Test case name | Result |
|---|---|
| strucutredClone | |
| JSON.parse(JSON.stringify()) |
| Test name | Executions per second |
|---|---|
| ✓ JSON.parse(JSON.stringify()) | 214,446 Ops/sec |
| strucutredClone | 105,766 Ops/sec |