graphql-tools icon indicating copy to clipboard operation
graphql-tools copied to clipboard

Allow using merge directive without keyArg argument if resolver takes 0 arguments

Open dimatillck opened this issue 3 years ago • 0 comments

Is your feature request related to a problem? Please describe.

Currently stitchingDirectivesValidator doesn't allow to use @merge directive without keyArg argument if resolver takes 0 arguments.

Describe the solution you'd like

Allow using @merge directive without keyArg argument if resolver takes 0 arguments

Additional context

Allow such use-case will be helpful for situations when there is a global object with fields resolved by different subschemas. An example of such use-case could be some global Stats Object which has different stat fields that are resolved by different subschemas, so there is nothing to pass to the merge resolver

dimatillck avatar Mar 25 '22 17:03 dimatillck