W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2011

Re: XPath and Selectors are identical, and shouldn't be co-developed

From: James Graham <jgraham@opera.com>
Date: Wed, 30 Nov 2011 22:16:01 +0100 (CET)
To: Yehuda Katz <wycats@gmail.com>
cc: Bjoern Hoehrmann <derhoermi@gmx.net>, "Tab Atkins Jr." <jackalmage@gmail.com>, public-webapps <public-webapps@w3.org>
Message-ID: <alpine.DEB.2.00.1111302212540.22524@sirius>


On Wed, 30 Nov 2011, Yehuda Katz wrote:

> 
> Yehuda Katz
> (ph) 718.877.1325
> 
> 
> On Wed, Nov 30, 2011 at 12:57 PM, Bjoern Hoehrmann <derhoermi@gmx.net> wrote:
>       * Yehuda Katz wrote:
>       >Most people would accomplish that using jQuery. Something like:
>       >
>       >var previous = $(current).closest("tr").prev()
>       >
>       >I'm not exactly sure what `current` is in this case. What edge-cases are
>       >you worried about when you say that the JavaScript is "quite involved"?
> 
> It is unlikely that your code is equivalent to the code I provided, and
> sure enough, you can point out in all discussions about convenience APIs
> that people could use a library. I don't see how that is relevant here.
> 
> 
> It's relevant because Tab's argument is that a mix of selectors and JS APIs will work, and I'm demonstrating that by showing that that's what *people actually do* today.

Of course that can be taken in one of two ways; it either shows that it's 
fine to have a limited selection DSL because people can fall back on using 
a full programming language, or shows that today's selction DSLs have 
failed because people are being forced to fall back on a full programming 
language and the whole of jQuery to satisfy their needs.
Received on Wednesday, 30 November 2011 21:16:43 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:49 GMT