Open xperiandri opened 7 months ago
Is it the correct behavior?
Yes. The relevant flow is:
selection
is InlineFragmentI guess currently it's a bit implicit in the sense that we say Initialize resultMap to an empty ordered map.
and then we see that the fragment does not apply so it stays an empty ordered map. I think there might be an opportunity to clarify something along the lines of If a returned object has no matching fragments the result will be an empty ordered map.
.
I think adding an example that demonstrates this might be helpful; the algorithm itself seems unambiguous.
Having types
Fruit
andVegetable
implementingProduce
as per https://graphql.com/learn/interfaces-and-unions/#fragments After I executed such query (use no shared fields, and only a sible type fragment while the collecton has multiple types)I've got
Is it the correct behavior?
Specification does not mention such case at all.
I want to understand both cases like:
In context of fixing https://github.com/fsprojects/FSharp.Data.GraphQL/issues/455 in https://github.com/fsprojects/FSharp.Data.GraphQL/pull/458