jaydenseric / graphql-react

A GraphQL client for React using modern context and hooks APIs that is lightweight (< 4 kB) but powerful; the first Relay and Apollo alternative with server side rendering.
https://npm.im/graphql-react
MIT License
717 stars 22 forks source link

Query resetOnLoad should reset all cache except what was loaded #3

Closed jaydenseric closed 6 years ago

jaydenseric commented 6 years ago

Currently the cache of what just loaded is also reset.

You can see it happening in the CreateTimer example mutation component; the success message instantly clears.

This would also allow the simultaneous use of resetOnLoad and loadOnReset props, which is currently prohibited due to an infinite loop.