Re: "match a selectors string" in the DOM spec doesn't do what it wants to be doing

On Fri, Aug 1, 2014 at 8:37 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:
> On 8/1/14, 2:28 PM, Tab Atkins Jr. wrote:
>> I can add whatever's needed, obviously.
>
> What's needed is something that takes a single element and the result of
> "parse a selector" [1] and returns a boolean for whether the parsed selector
> matches the element.
>
> [1] http://dev.w3.org/csswg/selectors/#parse-a-selector

If it started to return a boolean, the algorithm defined for
http://dom.spec.whatwg.org/#dom-element-matches would no longer make
sense. Nor would numerous other algorithms in DOM.


-- 
http://annevankesteren.nl/

Received on Monday, 4 August 2014 07:34:39 UTC