2 ms·
> which only holds true without interpolations. f`a${b}c`) becomes f("a", b, "c"). The difference is so subtle as to be irrelevant. You still need to manually
by dmitriid 8y ago
> which only holds true without interpolations. f`a${b}c`) becomes f("a", b, "c").
The difference is so subtle as to be irrelevant. You still need to manually parse, process and assemble strings. There’s no magic. There’s no code. It’s just strings (with some values here and there).
It’s enough to see the implementation of HTM (or lit-html or any other library using tagged literals) to see that.
> the answer is Babel
Which is only mentioned once the bullshit claims about tagged literals are refuted.
Babel is not exactly the answer, but as poor man’s macros it will do.