Open
Description
GraphQL-JS (the reference implementation) implements the values as an array of key->value.
This is done in order to allow parsing things like:
field(arg: { f: true, f: false })
And be able to have in the result [ {key: "f", value: true}, {key: "f", value: false }]
. Today it's just { f: false}
in graphql-parser
.
Where a field can be specified multiple times. In terms of parsing, it should be better to use the array.
The spec/graphql-js also implements a validation rule (UniqueInputFieldNamesRule
) to strictly enforce the existence of only one field.
Currently, this creates an ambiguity issue, since the consumer of the parsed Value
is getting the "latest" value specific.
Metadata
Metadata
Assignees
Labels
No labels