Comparaison between "", '' and `` for a simple string

Benchmark created on


Description

The purpose is to evaluate if using `` without interpolation (variable, function) is relevant.

Preparation HTML

<p id="my-para"></p>

Test runner

Ready to run.

Testing in
TestOps/sec
Using single quotes
document.getElementById('my-para').textContent = 'A few words...';
ready
Using double quotes
document.getElementById('my-para').textContent = "A few words...";
ready
Using backticks
document.getElementById('my-para').textContent =  `A few words...`;
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.