Toggle navigation
MeasureThat
.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
adding 1 char to a string
(version: 1)
Comparing performance of:
concatenation vs concat() vs interpolation
Created:
one year ago
by:
Guest
Go to the latest result
Script Preparation code:
let str = 'abc'.repeat(62)
Tests:
concatenation
str += 'def'
concat()
str = str.concat('def')
interpolation
str = `${str}def`
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (3)
Previous results
Fork
Test case name
Result
concatenation
concat()
interpolation
Fastest:
N/A
Slowest:
N/A
Latest run results:
Run details:
(Test run date:
one year ago
)
User agent:
Mozilla/5.0 (X11; CrOS x86_64 14541.0.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/132.0.0.0 Safari/537.36
Browser/OS:
Chrome 132 on Chrome OS 14541.0.0
View result in a separate tab
Embed
Embed Benchmark Result
interpolation
2.3M/s
concat()
2.2M/s
concatenation
566K/s
View exact numbers
Test name
Executions per second
✓
interpolation
2,265,901 Ops/sec
concat()
2,235,448 Ops/sec
concatenation
565,520 Ops/sec
Related benchmarks
String concat – `` vs concat
Comments
Confirm delete:
Do you really want to delete benchmark?