We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9591369 commit 235980fCopy full SHA for 235980f
src/ReactHTMLElement.ts
@@ -23,6 +23,8 @@ class ReactHTMLElement extends HTMLElement {
23
24
private _awaitingRoot = false;
25
26
+ private _app: Renderable | undefined;
27
+
28
private getShadowRoot(): ShadowRoot {
29
return this.shadowRoot || this.attachShadow({ mode: 'open' });
30
}
@@ -72,8 +74,9 @@ class ReactHTMLElement extends HTMLElement {
72
74
73
75
76
async renderRoot(app: Renderable): Promise<void> {
77
+ this._app = app; // this value may change while we wait for root...
78
const root = await this.root();
- root.render(app);
79
+ root.render(this._app); // always render current app
80
81
82
disconnectedCallback(): void {
0 commit comments