Tests:
-
JSON.parse(JSON.stringify())
-
structuredClone()
-
fast_deep_clone()
Rendered benchmark preparation results:
Latest run results:
Run details: (Test run date:
2 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/149.0.0.0 Safari/537.36
Chrome 149 on Windows
View result in a separate tab
JSON.parse(JSON.stringify())
2.3M/s
View exact numbers
| Test name |
Executions per second |
|
✓
fast_deep_clone()
|
7,977,544 Ops/sec |
|
JSON.parse(JSON.stringify())
|
2,299,849 Ops/sec |
|
structuredClone()
|
649,547 Ops/sec |
Do you really want to delete benchmark?