Skip to content

Commit

Permalink
implement suggestoins
Browse files Browse the repository at this point in the history
  • Loading branch information
e111077 committed Mar 29, 2023
1 parent a533b98 commit 4b9a03e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .changeset/gold-windows-fly.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
'@astrojs/lit': patch
'@astrojs/lit': major
---

Update to use `@lit-labs/ssr@^3`
Expand Down
7 changes: 4 additions & 3 deletions packages/integrations/lit/server-shim.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,10 @@ if (globalThis.HTMLElement) {
}

// Astro seems to have a DOM shim and the only real difference that we need out
// of the Lit DOM shim is that the Lit DOM shim does something that triggers
// ReactiveElement.finalize() to be called. So this is the only thing we will
// re-shim since Lit will try to respect other global DOM shims.
// of the Lit DOM shim is that the Lit DOM shim reads
// `HTMLElement.observedAttributes` which is meant to trigger
// `ReactiveElement.finalize()`. So this is the only thing we will re-shim since
// Lit will try to respect other global DOM shims.
globalThis.customElements = litCE;

const litCeDefine = customElements.define;
Expand Down

0 comments on commit 4b9a03e

Please sign in to comment.