W3C home > Mailing lists > Public > www-style@w3.org > February 2015

Re: element existence selector

From: Henrik Andersson <henke@henke37.cjb.net>
Date: Fri, 27 Feb 2015 18:04:23 +0100
Message-ID: <54F0A397.3070109@henke37.cjb.net>
To: "Tab Atkins Jr." <jackalmage@gmail.com>, Peter Krauss <ppkrauss@gmail.com>
CC: www-style list <www-style@w3.org>
Tab Atkins Jr. skrev:
> Unfortunately, this won't get into the fast profile (what's supported
> in stylesheets) for the same reason that full-powered :has() won't;
> it's way too slow, and makes invalidating styles too difficult, since
> a change *literally anywhere in the document* can affect whether the
> selector matches the e2 element.
Could you elaborate on why it is slow? As far as I understand it, for
initial evaluation it is at worst the sum of the individual selectors.

You mention invalidation being difficult, do you want to say that
browsers cache subtrees independently? To me it seems like that could be
solved with a pointer. Specifically, splitting the selector into the
subparts and letting each subpart let the other part know that it needs
to be reevaluated.
Received on Friday, 27 February 2015 17:04:56 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:52:01 UTC