- From: Keith Cirkel <notifications@github.com>
- Date: Mon, 29 Apr 2024 01:36:45 -0700
- To: WICG/webcomponents <webcomponents@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Monday, 29 April 2024 08:36:49 UTC
At the risk of spinning _another_ alternative proposal from this alternative proposal, the `MountObserver` looks quite close to something like a `SelectorObserver` - which could fire a callback whenever a given selector changes the amount of matched elements. Something like this was also discussed in https://github.com/whatwg/html/issues/7039 where folks wanted to know when an element transitions from e.g. `:dir(ltr)` to `:dir(rtl)`, and a few ideas were discussed around `matchSelector(the_selector).addEventListener('change', () => { .. })`. It seems like something more generic like this could benefit all of these use cases. -- Reply to this email directly or view it on GitHub: https://github.com/WICG/webcomponents/issues/896#issuecomment-2082161208 You are receiving this because you are subscribed to this thread. Message ID: <WICG/webcomponents/issues/896/2082161208@github.com>
Received on Monday, 29 April 2024 08:36:49 UTC