Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:127.0) Gecko/20100101 Firefox/127.0
Firefox 127
Windows
Desktop
6 months ago
Test name Executions per second
spread ... 23602720.0 Ops/sec
slice() 46389464.0 Ops/sec
splice(0) 23594314.0 Ops/sec
concat() 36881556.0 Ops/sec
JSON.parse(JSON.stringify()) 2271782.2 Ops/sec
Custom function 3584378.8 Ops/sec
Lodash.cloneDeep() 2245632.2 Ops/sec
jQuery.extend(true) 1586993.9 Ops/sec
HTML Preparation code:
Tests:
  • spread ...

  • slice()

  • splice(0)

  • concat()

  • JSON.parse(JSON.stringify())

  • Custom function

  • Lodash.cloneDeep()

  • jQuery.extend(true)


;