esquery icon indicating copy to clipboard operation
esquery copied to clipboard

ECMAScript AST query library.

Results 47 esquery issues
Sort by recently updated
recently updated
newest added

Using the following snippet in the [ESQuery demo](http://estools.github.io/esquery/): ```js var f = "foo/bar"; ``` None of these queries is parsed correctly and all fail with an error: `[value=/foo\/bar/]` > Invalid...

this is a weird bug that i noticed while writing an eslint rule with the following selector ImportDeclaration + :not(ImportDeclaration) for certain types of file using babel-eslint, this would throw...

The closest I could find is discusssed here but the pull request is not merged. https://github.com/estools/esquery/pull/45 In dom, once I get a node via css selector, I always have a...

Queries with subject indicators match more nodes than they should, and also match the same node multiple times. E.g.: ```JavaScript esquery(esprima.parse('foo = bar = baz'), '!AssignmentExpression > AssignmentExpression > Identifier');...

I'm trying to use grasp with squery which I think uses esquery under the hood? How do I match an import with a given specifier: I can't do `import-dec[specifiers=x]` since...

I’ve found that each time I use esquery I have a question how to use it? Is it conventional, like other estools: `var query = require('esquery').query` or is it plain...

I'm looking at using esquery in ESLint, and it looks very close to what I need for the implementation I have in mind. The one thing that is missing is...

Hopefully people will understand the performance consequences of calling these interfaces repeatedly with a string as selector.

enhancement

``` js var esprima = require('esprima'); var esquery = require('esquery'); var ast = esprima.parse('a + !b'); var query = esquery.parse('BinaryExpression! > UnaryExpression.right'); // should be true (does not work) console.log(esquery.matches(ast.body[0].expression,...