zino-hofmann / graphql-flutter

A GraphQL client for Flutter, bringing all the features from a modern GraphQL client to one easy to use package.
https://zino-hofmann.github.io/graphql-flutter
MIT License
3.25k stars 622 forks source link

feat(graphql_common): Add `deduplicatePollers`, `deepEquals`, and `queryRequestTimeout` parameters to `copyWith` method in `GraphQLClient` #1464

Open hamed-rezaee opened 3 weeks ago

hamed-rezaee commented 3 weeks ago

Summary: This PR adds deduplicatePollers, deepEquals, and queryRequestTimeout parameters to the copyWith method in the GraphQLClient class. Including these parameters in copyWith allows for more consistent client cloning.

Justification: Adding deduplicatePollers, deepEquals, and queryRequestTimeout parameters addresses a potential inconsistency in cloned instances. For example, the timeout might differ unexpectedly from the base client configuration. Without this cloned instances would always initialize with a 5-second timeout, which may lead to unanticipated request behavior.