New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Input Object fields #85
Comments
Can you share the introspection query in particular? GraphQL does not have a concept of keyed sets or maps, only lists, so I'm a little confused with the issue. inputFields and fields have different names in introspection because they return different types. Since introspection uses one simplified and flattened "__Type" type that can represent all of the types in a type system, it needs differently named fields to refer to these two different concepts. |
Apologies, I think I was confused. No, I was definitely confused. There is not a lot of literature on mutations in GraphQL, and therefore not a lot of literature on really big blobs of data in Input Objects. I was trying to tease out the implementation of GraphQL-JS vs the actual spec and Object vs Input Object. I went back and ran the introspections again now that I have significantly more experience with Input Object, I think perhaps I was leaving out the name field, which made the two seem different. Also, defining Sorry for wasting your time on this. |
No problem, this has been good feedback! |
Should input objects return a keyed set when introspecting for
inputFields
the way object do forfields
?Currently, the spec on introspection says that input objects have an
inputFields
query that returns a list. Object, on the other hand, have afields
query that returns a keyed set. Both input objects and objects take maps, even if the keys are just 0, 1, 2, 3. Is there a reason that introspection does not return a keyed set of fields for input objects? In a similar vein, why not just have the introspection query be 'fields' for both?The text was updated successfully, but these errors were encountered: