W3C home > Mailing lists > Public > www-style@w3.org > March 2013

Re: [selectors4][naming] Renaming :matches() (was: Proposal: Logical Combinators / Sets)

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Wed, 20 Mar 2013 17:10:26 -0700
Message-ID: <CAAWBYDApLXVV9nuzOa5HQ9BaF4EQxg61Cr5NpsK3_xRO4vSiHg@mail.gmail.com>
To: Peter Moulder <peter.moulder@monash.edu>, www-style list <www-style@w3.org>
On Wed, Mar 20, 2013 at 5:01 PM, Peter Moulder <peter.moulder@monash.edu> wrote:
> On Wed, Mar 20, 2013 at 11:28:35PM +0100, Simon Sapin wrote:
>> We discussed this on the conf call today. :any() is great when there
>> are multiple arguments:
>>
>>   some > long + combinator ~ chain:any(.foo, .bar)
>>
>> But one counter-argument that convinced me is that it doesn’t make
>> any sense with a single argument. This can be useful when that
>> selector contains combinators:
>>
>>   ol li:matches(aside li)
>
> Ooc, what's the reason that the above rule is (apparently quite deliberately)
> invalid in the current selectors4 ?  Just wondering whether that reason might
> be relevant to what the matches-any pseudo-class should be called.  E.g. I
> wonder whether there's a chance that we'll end up with a different name or
> syntax for combinators anyway, in which case the above argument might be moot.

Because complex selectors are more expensive than compound selectors.
(A lot more, afaik.)

~TJ
Received on Thursday, 21 March 2013 00:11:13 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:21:07 GMT