Skip to content

Commit ac9fdbc

Browse files
committed
conciser validation
1 parent 7cad383 commit ac9fdbc

File tree

1 file changed

+0
-16
lines changed

1 file changed

+0
-16
lines changed

spec/Section 5 -- Validation.md

-16
Original file line numberDiff line numberDiff line change
@@ -579,35 +579,19 @@ fragment conflictingDifferingResponses on Pet {
579579

580580
Fragment spread arguments can also cause fields to fail to merge.
581581

582-
While the following is valid:
583-
584582
```graphql example
585583
fragment commandFragment($command: DogCommand!) on Dog {
586584
doesKnowCommand(dogCommand: $command)
587585
}
588586

589587
fragment potentiallyConflictingArguments(
590588
$commandOne: DogCommand!
591-
$commandTwo: DogCommand!
592589
) on Dog {
593590
...commandFragment(command: $commandOne)
594591
...commandFragment(command: $commandTwo)
595592
}
596593

597594
fragment safeFragmentArguments on Dog {
598-
...potentiallyConflictingArguments(commandOne: SIT, commandTwo: SIT)
599-
}
600-
```
601-
602-
it is only valid because `safeFragmentArguments` uses
603-
`potentiallyConflictingArguments` with the same value for the fragment-defined
604-
variables `commandOne` and `commandTwo`. Therefore `commandFragment` resolves
605-
`doesKnowCommand`'s `dogCommand` argument value to `SIT` in both cases.
606-
607-
However, by changing the fragment spread argument values:
608-
609-
```graphql counter-example
610-
fragment conflictingFragmentArguments on Dog {
611595
...potentiallyConflictingArguments(commandOne: SIT, commandTwo: DOWN)
612596
}
613597
```

0 commit comments

Comments
 (0)