-
In my GraphQL project, we have multiple subgraphs that use the same types and models. Each subgraph is scoped in its own folder. Such as:
Each subgraph imports The problemI don't want each query field to have to specify the subgraph it belongs to. It is tedious and prone to human errors. What I thought of doingI thought of building a higher abstraction over the However this is not possible due to the thunk pattern. I also thought of modifying the field after it has been created and manually setting the Any ideas 💡? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
This will become easier in Pothos v4. I don't think there is currently a good way to do this that isn't a hack |
Beta Was this translation helpful? Give feedback.
I got it working by overriding queryField and doing something like this: