- From: Mason Freed <notifications@github.com>
- Date: Mon, 29 Jan 2024 11:48:31 -0800
- To: whatwg/dom <dom@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Monday, 29 January 2024 19:48:37 UTC
### What is the issue with the DOM Standard?
This issue was [raised as part of the Chromium review](https://chromium-review.googlesource.com/c/chromium/src/+/5239277/comment/3d66eb39_1ccfcf33/) of the implementation of `clonable`. The question is what should happen here:
```javascript
const shadow = host.attachShadow({mode: 'open', clonable: true});
shadow.innerHTML = '<div><span>what about me?</span></div>`;
const clone = host.cloneNode(false);
```
What should happen to the shadow root? Since it is clonable, I'd expect `clone` to have a shadow root, with parameters that match `shadow`. But should the *content* of that shadow root be deep-cloned from `host`? Or should `clone.shadowRoot` be empty? Both of those feel slightly odd. I think I slightly prefer deep-cloning the shadow content, but I'm not sure.
@dbaron @annevk @saschanaz
--
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/dom/issues/1249
You are receiving this because you are subscribed to this thread.
Message ID: <whatwg/dom/issues/1249@github.com>
Received on Monday, 29 January 2024 19:48:37 UTC