This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { absolutizeRelativeSelectorList } from "http://dev.w3.org/csswg/selectors/#absolutizing"; | |
// Assume JSIDL conversions have been applied already, | |
// i.e. we don't do `selectors = String(selectors)` manually. | |
class Elements extends Array { | |
query(selectors) { | |
return this.queryAll(selectors)[0]; // highly inefficient obviously, but clear semantics | |
} | |
queryAll(selectors) { |