My entire schema is split into different files except for my queries and mutations which I cant seem to separate. I tried defining type Query {} and type Mutation {} in root.graphql, then defining my custom queries and mutation in different files using extend type Query and extend type Mutation but I get this error: Cannot extend nonexistent type 'Mutation'.
#Difficulty splitting schema into different files, more specifically using "extend type Query"
3 messages · Page 1 of 1 (latest)
Behaviour is very strange, I thought maybe the transformer reads/considers every file in alphabetical order, one at a time, and it seems like it does, because if I rename my root.graphl to a.graphql , I get this new error:
Object type extension 'Mutation' cannot redeclare field <insert-a-mutation-i-declared-inside-extend-type
The error is telling me I am redeclaring some mutation field but in reality, I am only declaring it once. Very confused as to what is going on here.