File tree Expand file tree Collapse file tree 3 files changed +12
-1
lines changed
Expand file tree Collapse file tree 3 files changed +12
-1
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ " @patternfly/pfe-core " : patch
3+ " @patternfly/elements " : patch
4+ ---
5+ Enable context protocol in SSR scenarios.
Original file line number Diff line number Diff line change @@ -7,6 +7,11 @@ function makeContextRoot() {
77 const root = new ContextRoot ( ) ;
88 if ( ! isServer ) {
99 root . attach ( document . body ) ;
10+ } else {
11+ root . attach (
12+ // @ts -expect-error: enable context root in ssr
13+ globalThis . litServerRoot ,
14+ ) ;
1015 }
1116 return root ;
1217}
Original file line number Diff line number Diff line change @@ -34,6 +34,8 @@ globalThis.window ??= globalThis;
3434globalThis . document ??= new MiniDocument ( ) ;
3535// @ts -expect-error: this runs in node
3636globalThis . navigator ??= { userAgent : '' } ;
37+ // @ts -expect-error: opt in to event support in ssr
38+ globalThis . litSsrCallConnectedCallback = true ;
3739// @ts -expect-error: this runs in node
3840globalThis . ErrorEvent ??= Event ;
3941// @ts -expect-error: this runs in node
@@ -55,4 +57,3 @@ globalThis.getComputedStyle ??= function() {
5557}
5658
5759;
58-
You can’t perform that action at this time.
0 commit comments