replaceWith vs replaceChildFastest: replaceWith (1.3x faster)
19 ops/sec
14 ops/sec
Fastest: replaceWith (1.2x faster)
73 ops/sec
59 ops/sec
Results show median performance across all community submissions. Run this benchmark yourself to verify on your device.
| Test case name | Result |
|---|---|
| replaceWith | |
| replaceChild |
| Test name | Executions per second |
|---|---|
| ✓ replaceWith | 4 Ops/sec |
| replaceChild | 3 Ops/sec |