Writing custom GraphQL Layer

I was reviewing Dgraph support for GraphQL, and opted to write custom GraphQL over which I’ve more control, while still using DGraph as db.

Could you pls provide any recommendations, links on how to convert resolvers for nested query from GraphQL into DQL, as DQL does have good support to fetch nested information in kind of GraphQL way. Is there any way to leverage that while having my own GraphQL layer.

I’m using gqlgen with golang to implement GraphQL layer.

Look at Dgraph’s source code for how they implement a query rewriter from GraphQL to DQL: