On Wed, Jan 5, 2011 at 3:04 AM, Tim Starling <[email protected]> wrote:
> CSS selectors are the worst part of jQuery, I wish they weren't in it.
> Sizzle is slow and bulky -- necessarily so considering what it does,
> but a more sensible function-based API could have exposed a rich
> feature set to users without introducing nearly so much overhead.

In recent browsers (including IE8), you should be able to implement
selectors very efficiently with querySelector() and
querySelectorAll().  I should hope jQuery does this.

> PHP already provides XPath, which is integrated with the DOM extension
> and is just as feature-rich as CSS. We use it in the ImageMap
> extension. So if you wanted an insecure text protocol for DOM node
> selection, you could just use that.

Pretty much every web developer already knows selectors, though, while
almost nobody uses XPath.

_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to