[typescript-operations] Any way to automatically add a field to queries if it exists in the schema? #4656
-
With the existing options on We're currently using a lint rule to require it, but two issues with that:
If not, would this be generally useful to add? I can contribute if we can agree on an option name. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Hi @threehams |
Beta Was this translation helpful? Give feedback.
Hi @threehams
Codegen doesn't do schema/operations manipulations or that level. You can do that with a custom document loader: https://graphql-code-generator.com/docs/getting-started/documents-field#custom-document-loader