Test case name | Result |
---|---|
spread ... | |
slice() | |
splice(0) | |
concat() | |
JSON.parse(JSON.stringify()) | |
Custom function | |
Lodash.cloneDeep() | |
jQuery.extend(true) |
Test name | Executions per second |
---|---|
spread ... | 10342152.0 Ops/sec |
slice() | 12312926.0 Ops/sec |
splice(0) | 8494203.0 Ops/sec |
concat() | 10729037.0 Ops/sec |
JSON.parse(JSON.stringify()) | 929031.1 Ops/sec |
Custom function | 784219.3 Ops/sec |
Lodash.cloneDeep() | 345847.9 Ops/sec |
jQuery.extend(true) | 363095.3 Ops/sec |