Created
April 17, 2022 21:49
-
-
Save colinfwren/e59c63e6679648cc9c29732666fc6417 to your computer and use it in GitHub Desktop.
Query schema with connections to get linked nodes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
query Query { | |
products { | |
name | |
userStoriesConnection { | |
edges { | |
author | |
node { | |
name | |
} | |
} | |
} | |
} | |
mockups { | |
name | |
tests { | |
name | |
} | |
userStories { | |
name | |
} | |
} | |
} | |
""" | |
Returns | |
{ | |
data { | |
products [ | |
{ | |
name: 'Chocolate Box', | |
userStoriesConnection: { | |
edges: [ | |
{ | |
author: 'Colin', | |
node: { | |
name: 'Customer Views Chocolates Product List' | |
} | |
} | |
] | |
} | |
} | |
], | |
mockups [ | |
{ | |
name: 'Landing Page', | |
tests: [ | |
{ | |
name: 'Existing User buys Flowers' | |
} | |
] | |
} | |
] | |
} | |
} | |
""" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment