W3C home > Mailing lists > Public > public-webapi@w3.org > May 2008

Re: [SelectorsAPI] Thoughts on querySelectorAll

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Thu, 01 May 2008 02:35:47 +0200
To: John Resig <jresig@mozilla.com>
Cc: public-webapi@w3.org
Message-ID: <7m3i1497uljahglsptisc8t303rsjq352f@hive.bjoern.hoehrmann.de>

* John Resig wrote:
>This is due to the fact that element-rooted queries are handled by
>"finding all the elements that match the given selector -- rooted in the
>document -- then filtering by the ones that have the specified element
>as an ancestor." This is completely unacceptable. 

I agree with this, clearly this should be defined that the matching
occurs as if each of the parts in the group had been prefixed by a
selector matching the context node and only the context node and a
descendant combinator, so e.querySelector("x") would just be short
for ...querySelector("... > *:nth-child(a) > ... > *:nth-child(n) x")
or equivalent.
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 
Received on Thursday, 1 May 2008 00:36:33 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:16:26 UTC