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
Currently, HotChocolate names the query convention result types by the field.
I have several fields in different parts of the hierarchy with the same name, and I need to use query conventions for both.
The solution you'd like
The ability to override the query convention result type name per field using an attribute, just like overriding the result type name for mutation conventions or the connection name for pagination.
The text was updated successfully, but these errors were encountered:
To be clear, if I currently have two identically named fields (in different parts of the hierarchy) that both use query conventions, then fetching the schema fails with:
The name SomeFieldNameResult was already registered by another type. (HotChocolate.Types.UnionType)
Ideally, there'd be a global option to automatically name the field similar to MutationConventionOptions.PayloadTypeNamePattern, which would allow me to set something like "{TypeName}{FieldName}Result". (I would argue that should be the default naming, but as long as I can configure it, I'm happy.)
Product
Hot Chocolate
Is your feature request related to a problem?
Currently, HotChocolate names the query convention result types by the field.
I have several fields in different parts of the hierarchy with the same name, and I need to use query conventions for both.
The solution you'd like
The ability to override the query convention result type name per field using an attribute, just like overriding the result type name for mutation conventions or the connection name for pagination.
The text was updated successfully, but these errors were encountered: