Re: [w3c/webcomponents] <iframe> and the History API (#184)

I haven't read too far past https://github.com/w3c/webcomponents/issues/184#issuecomment-211221983, but for number 3 to be possible, which is

> Design iframe elements differently inside shadow trees so they do not put properties on the global object and don't interfere with the history of the browsing context. Could be quite a bit of work, I haven't had time to investigate yet.

then this means that Nodes that are distributed into a ShadowDOM tree (into slot elements) must somehow be aware that they have been distributed into a ShadowDOM tree (even if the tree is closed) in order to decide to behave differently than when not in a ShadowDOM tree. There is currently no part of webcomponents spec (as far as I'm aware, please let me know if otherwise) that would explain how a Node can possibly be aware of such a thing as having been distributed into a shadow tree.

So, this leads me to link here to an idea I made earlier: [`distributedCallback`](https://github.com/w3c/webcomponents/issues/527). The `slot` argument to `distributedCallback` is `null` when the shadow tree that the element is distributed into is closed. This method could possibly be the explanation as to how an `<iframe>` can possibly know to behave differently inside a shadow tree, if that route is taken with iframes.

---
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/184#issuecomment-228968745

Received on Tuesday, 28 June 2016 07:07:51 UTC