Lowers an HTML import into a module-level <template> that is parsed once,
so every component instance clones it instead of re-parsing markup — the
markup analog of the constructable-stylesheet lowering in lowerCssImports:
importtplfrom'./card.html'; // …in the constructor: root.appendChild(tpl.content.cloneNode(true));
The HTML file is read at compile time and inlined as a JS string literal (it
is author-controlled source, like the component itself). Imports with no
default binding, or whose HTML file can't be read, are left as-is.
Lowers an HTML import into a module-level
<template>that is parsed once, so every component instance clones it instead of re-parsing markup — the markup analog of the constructable-stylesheet lowering inlowerCssImports:becomes, in the emitted module:
The HTML file is read at compile time and inlined as a JS string literal (it is author-controlled source, like the component itself). Imports with no default binding, or whose HTML file can't be read, are left as-is.