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 working with GraphQL documents, it's essential to ensure that the structure conforms to a normalized format to prevent inconsistencies and improve compatibility with various tools and libraries.
Proposed solution
Implement a GraphQLNormalizer in @har-sdk/core package, make sure the GraphQLImporter executes normalization upon successful deserialisation of an introspection query or conversion of SDL schema.
Ensure the non-optional properties are present in case the properties format are obvious, e.g.
Normalizing the kind property for query, mutation, and subscription types to 'OBJECT' if they are not already specified
Normalizing the structure of directives and types (including object types, interface types, union types, and input object types), fields, interfaces, possible types, input fields, and arguments by ensuring the unexpected null arrays are superseded with empty ones
Expected results
The GraphQL normalizer, given a non-compliant document, should normalize it as follows:
When working with GraphQL documents, it's essential to ensure that the structure conforms to a normalized format to prevent inconsistencies and improve compatibility with various tools and libraries.
Proposed solution
Implement a
GraphQLNormalizer
in @har-sdk/core package, make sure theGraphQLImporter
executes normalization upon successful deserialisation of an introspection query or conversion of SDL schema.Considerations
null
arrays are superseded with empty onesExpected results
The GraphQL normalizer, given a non-compliant document, should normalize it as follows:
The text was updated successfully, but these errors were encountered: