Re: [w3c/webcomponents] shadow tree -> iframe <- contentWindow.frameElement encapsulation issue (#507)

So you want the iframe inside a closed shadow tree to be able to access to the tree outside the shadow tree?

I think the best way to do something like that would be put all your shadow tree's implementation into another closed shadow tree. e.g.
```js
var outerShadow = outerElement.attachShadow({mode: 'closed'});
outerShadow.appendChild(document.createElement('iframe'));
var innerHost = document.createElement('div');
outerShadow.appendChild(innerHost);
var innerShadow = innerHost.attachShadow({mode: 'closed'});
innerShadow = ... // your implementation details
```

If that's not possible, then we need a new opt-in API for this. We can't change the behavior of all iframe like this because that would make it impossible for inner iframe to access shadow tree.

---
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/507#issuecomment-222282870

Received on Saturday, 28 May 2016 01:26:55 UTC