Query & Mutation splitting #3235
undercoverfemboy
started this conversation in
General
Replies: 1 comment
-
There are many ways to split code. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello.
I'm creating a webapp and I have really long RootQuery, with many other queries in it. Is there any way to split code beetwen files?
My code looks like this(it's only a small part of it):
const RootQuery = new GraphQLObjectType({ name:'RootQuery', fields:{ getUser:{ type:UserType, resolve(parent,args,request){ return request.user ? request.user : {errMsg: 'User not logged in'}; } }, } })
Beta Was this translation helpful? Give feedback.
All reactions