Re: [w3c/webcomponents] How can a custom element detect when it is transcluded into a shadow tree (slotchange)? (#504)

I'd like to also note that in React this is [super easy to do](https://facebook.github.io/react/tips/communicate-between-components.html), thanks again to JavaScript scoping.

Another key difference between React and Web Components is that Reacts life cycle methods are called based on the flat tree, not the light tree. What I mean is with Custom Elements the `connectedCallback` is called when the element is appended into the light tree / outer tree. In React, the similar `componentDidMount` method is called when the element is appended into the inner tree as far as what React considers an "inner tree" to be.

---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/webcomponents/issues/504#issuecomment-224119685

Received on Monday, 6 June 2016 23:31:06 UTC