Re: [csswg-drafts] [selectors] Backwards combinators (#12453)

>  at least for bounded combinators like parent and previous sibling, simply having them could make them more performant than the `:has()` version.

I think this, for me, is the biggest argument to add something like this. Making the bounded versions easier to access will really make a difference.

The main issue that I see is that inverting the order of things in a selector can be confusing. It is understandable that we'd want to keep the subject on the right, but then how do we treat complex selectors?

`A C < B` — if this is the same as `A B:has(> C)`, it makes it really difficult to read at a glance.

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


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

Received on Monday, 7 July 2025 06:48:41 UTC