Re: QSA, the problem with ":scope", and naming

Ok, so we're down to not having full agreement on the following selectors:

On Mon, Oct 31, 2011 at 1:55 PM, Alex Russell <slightlyoff@google.com> wrote:
> On Fri, Oct 21, 2011 at 12:41 AM, Jonas Sicking <jonas@sicking.cc> wrote:
>> e.findAll("body > :scope > div")
>
> 1, 2, 3, 4
>
>> e.findAll("body > :scope > div, :scope")
>
> context, 1, 2, 3, 4

I'm hoping that you just made a mistake here? 4 isn't a child of the
context node. So in both of these I would think that 4 should be
removed based on your answers to the other questions.

>> e.findAll("div, :scope")
>
> context, 1, 2, 3, 4

Yehuda had a very different suggestion here but so far hasn't motivated why.

Personally I think Alex answer is the more useful one.

We just need to decide on something

>> e.findAll(":not(:scope)")
>
> empty set

Again, Yehuda had a different answer here. Though in this case I think
Yehuda's answer is more useful and consistent.

But I'm all ears for what the logic used to get to your answer and why
you think this is a better (more consistent? more useful?) answer.

/ Jonas

Received on Monday, 31 October 2011 21:20:56 UTC