You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the @lit-labs/ssr-dom-shim package throws when it encounters and element that includes a call to HTMLElement.prototype.attachInternals. This feature is shipped in Chrome, Firefox and Safari Technology Preview and should generally be called in an element's constructor which is one of the methods that will be called by Lit's SSR.
Because Lit uses a lightweight DOM shim, the polyfill cannot add a function to the HTMLElement prototype.
Alternatives and Workarounds
As the author of the element-internals-polyfill I attempted to patch HTMLElement.prototype.attachShadow in that file to no avail. Alternatively component authors could check for the presence of attachInternals in their components but that puts undue burden on Lit's consumers.
The text was updated successfully, but these errors were encountered:
Should this be an RFC?
Which package is this a feature request for?
Other/unknown (please mention in description)
Description
Currently the
@lit-labs/ssr-dom-shim
package throws when it encounters and element that includes a call toHTMLElement.prototype.attachInternals
. This feature is shipped in Chrome, Firefox and Safari Technology Preview and should generally be called in an element's constructor which is one of the methods that will be called by Lit's SSR.Because Lit uses a lightweight DOM shim, the polyfill cannot add a function to the
HTMLElement
prototype.Alternatives and Workarounds
As the author of the
element-internals-polyfill
I attempted to patchHTMLElement.prototype.attachShadow
in that file to no avail. Alternatively component authors could check for the presence of attachInternals in their components but that puts undue burden on Lit's consumers.The text was updated successfully, but these errors were encountered: