You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi there, thanks for the great library! I was just wondering if it's possible to programmatically coerce an input (i.e. an array) to match a given GraphQL type. For example, I have this PHP type:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi there, thanks for the great library! I was just wondering if it's possible to programmatically coerce an input (i.e. an array) to match a given GraphQL type. For example, I have this PHP type:
And then I have this GraphQL type:
Now I would like to take the
User
GraphQL type as a base and use the value so I can get a "sanitized" output:Is this somehow possible? Thanks!
P.S.: I found this https://github.com/webonyx/graphql-php/blob/master/src/Utils/Value.php but it's just for
InputType
Beta Was this translation helpful? Give feedback.
All reactions