You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I want to generate more than just XyzResolver interfaces.
Like XyzResolverImpl and XyzService interfaces.
Describe the solution you'd like
A few more variables in the templates.
The className without the suffix.
The type of the operation (Mutation, Query, Subscription), so I can generate the @SchemaMapping annotation.
A way to generate these into their own files and directories.
Current workarounds
I can split the current className by using ?keep_before("Resolver"). That works but bloats the template, since that's done in numerous places.
But generating the @SchemaMapping is currently impossible I think, as I have no way of knowing the type.
Currently I just have them in one file. That's not so bad and is not a priority, but it would be very nice to expand this even further in the future, so that eg. the service interfaces lie in their own package. A generic mechanism would be awesome so you could generate variable amounts of files into variable directories without having them hard coded as model and api.
Activity
[-]Template variables more fine grained[/-][+]Templates more flexible[/+]MartyWind commentedon Sep 11, 2023
To 1:
I can also work around that by checking if the name of the generated class contains
MutationorQuery.So for now I can do everything I want, but more flexibility, especially regarding the generated files, would be nice.