Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36
Chrome 120
Mac OS X 10.15.7
Desktop
10 months ago
Test name Executions per second
spread ... 868695.6 Ops/sec
esDeepClone2 228574.2 Ops/sec
JSON.parse(JSON.stringify()) 294144.7 Ops/sec
Custom function 272833.4 Ops/sec
Lodash.cloneDeep() 216359.9 Ops/sec
jQuery.extend(true) 195583.3 Ops/sec
Object.assign 817490.1 Ops/sec
chatGptDeepClone 6165695.0 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • spread ...

  • esDeepClone2

  • JSON.parse(JSON.stringify())

  • Custom function

  • Lodash.cloneDeep()

  • jQuery.extend(true)

  • Object.assign

  • chatGptDeepClone