Graphql-tools: Directives not working in query fields

Created on 14 Feb 2018  路  3Comments  路  Source: ardatan/graphql-tools

I'm trying to create new directives to be used in query fields similar to @include and @skip. However, the resolver never executes. If I change it to be applied in the schema, the resolver executes fine.

Here's a launchpad example showing both

https://launchpad.graphql.com/lk9vwjrmwq

Most helpful comment

Have same issue here. Using graphql-directive doesn't work either. Anyone solved this?

All 3 comments

I have been running into the same problem. The PR for the custom directives feature indicates that directives on queries are not supported yet.

The work around suggested in that thread is graphql-directive, which is the same project @jbaxleyiii linked you to in Slack.

Closing the issue!

Have same issue here. Using graphql-directive doesn't work either. Anyone solved this?

Was this page helpful?
0 / 5 - 0 ratings