@sharyn/tags.html

html is a template string tag that does nothing. It's a normal template string, but your code editor or its plugins (lit-html or es6-string-html for VSCode) might support syntax highlighting for HTML when they are marked with an html tag.

Usage no npm install needed!

<script type="module">
  import sharynTagsHtml from 'https://cdn.skypack.dev/@sharyn/tags.html';
</script>

README

🌹 html

html is a template string tag that does nothing. It's a normal template string, but your code editor or its plugins (lit-html or es6-string-html for VSCode) might support syntax highlighting for HTML when they are marked with an html tag.

const createHtml = ({ title }: { title: string }) =>
  html`
    <!DOCTYPE html>
    <html lang="en">
      <head>
        <title>${title}</title>
      </head>
      <body>
        <h1>${title}</h1>
      </body>
    </html>
  ` // This HTML code has syntax highlighting