You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using codegen on the generated graphql schema (e.g. in Typescript). It becomes frustrating to add tons of boilerplate just to handle nodes or edges not existing in results.
In the GraphQL schema, edges and nodes should be made non nullable.
If there are no edges it should be an empty array.
A node should simply not be in the array if it is null so that should also be non-nullable.
Summary 💡
Similar to graphql/graphql-relay-js#185
Motivation 🔦
When using codegen on the generated graphql schema (e.g. in Typescript). It becomes frustrating to add tons of boilerplate just to handle nodes or edges not existing in results.
As an example:
vs.
The text was updated successfully, but these errors were encountered: