-
Notifications
You must be signed in to change notification settings - Fork 379
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
importNode and adoptNode should throw with passed a ShadowRoot #125
Comments
Does this necessitate a change in the DOM L4 spec? https://dom.spec.whatwg.org/#dom-document-importnodenode-deep to something along these lines (also adding the caveat for
|
In general basically all of the shadow DOM spec is a giant patch on the DOM spec, so that wouldn't be surprising. I would expect eventual integration once we get something shipping in multiple browsers... |
Yeah, upstreaming Shadow DOM spec to DOM spec has been a long term goal for years. For a small change like this, I think it's okay to update DOM spec directly rather than Shadow DOM spec. |
BTW, we can use |
@samgiles would you be willing to submit a PR to https://github.com/whatwg/dom? |
Thanks. Let me close this issue. |
Given that cloneNode throws with a shadow root, importNode should also throw because one of the steps in the import algorithm it to clone the node. Also, adoptNode should also throw because the host and shadow root shouldn't have different node documents.
The text was updated successfully, but these errors were encountered: