DEV Community

David Newberry
David Newberry

Posted on

Tagged String Literals

I love seeing a line of code and thinking, I can not parse that. And then learning to parse it.

This is valid JavaScript:

JavaScript code: console.log raw `foo` endraw

This is an instance of using a tagged template string.

This works too:

Another example of using tagged template strings

These examples are from MDN. Learn more there. I have no use for this knowledge right now, but one day I may!

Top comments (0)