For example I want to implement a directive resolver
isPostOwner
. How would I get the
postID
from the query/mutation?
j
Jenkins
06/30/2018, 5:52 PM
Hey man! Sorry to reply to you late. Not 100% I'm sure what you're asking for, but if I'm getting right, you want a directive that you're going to add to a query? Can you send me a snippet of your schema so we can ponder together?
a
artindaniel
07/02/2018, 9:25 AM
Hey, thanks for the reply. I think I found a solution for my problem. I'm using graphql-shield now. My intention was to have a custom directive that would, depending on the mutation params, give the user access to this mutation.
j
Jenkins
07/02/2018, 10:47 AM
Good to hear! I solved this by making my own directives 😛 Glad to hear Shield works for you!