- From: Sean Hogan <shogun70@westnet.com.au>
- Date: Sat, 26 Nov 2011 00:34:26 +1100
- To: Lachlan Hunt <lachlan.hunt@lachy.id.au>
- CC: public-webapps@w3.org
On 26/11/11 12:00 AM, Lachlan Hunt wrote: > On 2011-11-25 00:19, Sean Hogan wrote: >> This has been raised before, but I'll restate it here. >> >> How should the selector be expanded in >> elt.findAll("div span, div :scope span")? > > The implication of :scope has to be done on a per complex selector > basis, rather than applied to the entire list. That would be > equivalent to: > > elt.findAll(":scope div span, div :scope span") > >> If this isn't to throw an error then a more complex definition is >> required which can apply a different rule for implying :scope in >> different parts of the selector argument. This is sure to be confusing >> for anyone reading the code. > > Selectors in selector lists are always independent of each other, so > authors who use a selector list would likely assume that one doesn't > affect how another in the list matches. It would seem far more > confusing for authors to do it using the other alternatives. > Discussion on this list has indicated that allowing explicit :scope in findAll() is confusing, which-ever definition is used. OTOH, there has been little or no confusion about how findAll() would behave if :scope is always implied. Do you expect the general web-dev community to be different?
Received on Friday, 25 November 2011 13:34:56 UTC