The thing with template strings is that they are used at runtime. This
could be slow if we're compiling things at runtime all the time,
whereas a server-side templating solution might lead JavaScript
functions compiled from templates (like in the case with Meteor Blaze
Spacebars or React JSX), which can be faster at runtime.

What are template strings good for besides the obvious benefit that
they make things like

```
var str = "llo"
console.log(`he${str} world!`)
```

easier to read than

```
var str = "llo"
console.log('he'+'str'+' world!')
```

?

Maybe writing regexes can be nicer with template strings? I gave it a
try at npmjs.com/regexr.

On Mon, Jan 11, 2016 at 8:43 AM, Manuel Di Iorio <[email protected]> wrote:
> Yes Bob, after a personal testing with a complete template engine using the
> ES6 template strings, I realized that their use (in mine use case, of
> course) is slowest than the approach that I'm using right now (like the
> Underscore template). Thanks everyone :)
>
> _______________________________________________
> es-discuss mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/es-discuss
>
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to