Re: [w3c/webcomponents] [idea] childConnectedCallback and childDisconnectedCallback (#550)

I also just ran into this issue and put together an example. The MutationObserver only handles the case where children are added, hopefully it's self evident how to handle the removal case.

I process any existing children in my connectedCallback, and from then on rely on the MutationObserver for any changes.

Would the folks on this thread mind taking a look and let me know if there are any issues with this approach? https://stackblitz.com/edit/custom-element-mo?file=index.html

-- 
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/550#issuecomment-373145977

Received on Wednesday, 14 March 2018 19:27:56 UTC