In a web component, can this throw? class MyComponent extends HTMLElement { constructor() { super(); this.constructed = true; } connectedCallback() { if (!this.constructed) throw 'Lifecycle design is important' } }
-
-
Right, but I think sync-calling connectedCallback post sync-calling the constructor would be fine. Like 2 lines var element = elementFactory() element.connectedCallback();
- 4 more replies
New conversation
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.
& Web Standards TL; Blink API OWNER
Named PWAs w/
DMs open. Tweets my own; press@google.com for official comms.
