GraphQL icon indicating copy to clipboard operation
GraphQL copied to clipboard

ASTField query, not its subqueries

Open ghost opened this issue 5 years ago • 1 comments

Hi, thanks for this great repo.

I suggest we get the $ast itself up to the ResolveInfo, not its subfields ($astFields), since we could want to retrieve its location. Example : in a Resolve callback, of a specific field, we could check if user has sufficient rights to read the field, and if not nullify the value and add an error to the ExecutionContext with Location information inside the message (line, column).

I did a fork to get this working, but I'd love to hear about you on this.

Thanks

ghost avatar Feb 22 '20 23:02 ghost

Feel free to make a PR if you already have it coded up.

Jalle19 avatar Feb 24 '20 10:02 Jalle19