<template src="/partial.html" for=""></template>
Together with the declarative API, it will also include a way to import HTML in JavaScript:
import fragment from "/partial.html" with { type: "fragment" }
252 karma · joined September 13, 2022
<template src="/partial.html" for=""></template>
Together with the declarative API, it will also include a way to import HTML in JavaScript:
import fragment from "/partial.html" with { type: "fragment" }
AFAIK Ryan Carniato/Solid JS is still exploring what’s possible with signals. I don’t think userland exploration of this space has entirely finished, and further innovation may be possible.
That proposal hasn’t just stalled, it’s been withdrawn. https://github.com/tc39/proposal-record-tuple/issues/394
It has been replaced by https://github.com/tc39/proposal-composites
There is an alternative suggestion to DOM parts which might be a better bet: https://github.com/whatwg/dom/issues/736
setHTML() is already implemented in Chrome/Edge and Firefox so this point is a bit outdated - there is a safe alternative to innerHTML.