graphql-go / graphql-go/graphql

Knowing the requested keys

Open
#325 7 comments 7 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
10.1k
Forks
845
PR merge metrics
No merged PRs in 30d

Description

Hi,
I see that is not possible to see in the resolver what fields have been requested in the query:

myQuery {
id
field1
field2
}

In some queries like stats it would be nice to know i.e. if we have to return field1 or not so that we can make the right query to the database. I don't think it is possible at the moment, and I wasn't able to understand where this is captured when running .Do.

Would it be possible to add this feature if not available?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.