Re: [csswg-drafts] How to implement and shape API for `<selectedoption>` element for `<select>` (#10242)

> Thanks! Right, microtask timing might be preferable to avoid cloning too often. As for your last point, `<selectedoption>` is inserted before any of `<option>` elements, so that does not address my question. But I guess we need to watch for mutations to those `<option>` elements, so maybe that would fall out automatically.

When the `<option>` element is inserted, the `<selectedoption>` will be updated to match the new `<option>` if the new option considered to be the selected option by the `<select>`. Any time that the `<select>` thinks that the currently selected option is changed, then it will update the contents of `<selectedoption>`, and `<option>` insertion falls into that category.

-- 
GitHub Notification of comment by josepharhar
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10242#issuecomment-2174567066 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 17 June 2024 22:48:40 UTC