-
Notifications
You must be signed in to change notification settings - Fork 109
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
fix refetch after error #141
base: master
Are you sure you want to change the base?
Conversation
const lastError = observableQuery.getLastError(); | ||
const lastResult = observableQuery.getLastResult(); | ||
|
||
if (!suspend) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
without this suspend test would fails, I'm not sure if it will breaks something.
@trojanowski any chance of merging and releasing this? 🙏 It fixes the error I'm seeing in our app 🙂 |
Could you add a unit test for it? To ensure that it won't be back after #134 is merged. |
@trojanowski a test case has been added but I think it's a little ugly. the other approach that came to my mind was to expose |
We tried this PR in our project and it works (fixes the problem), but there's one minor issue that could be fixed probably: Right now, Buut we can leave it as a separate issue and merge it PR in the meantime anyways ;] |
|
Any update on this PR? Would be really great to see this merged. |
you should probably use @apollo/react-hooks |
I started using it as well, but I really really miss the elegance and ease of use of Suspense. |
I understand. However Is there something missing in this PR or could it be merged as-is? As @huidini mentioned, using Suspense might still be a feature only this library has. |
@amannn https://github.com/apollographql/react-apollo/releases/tag/%40apollo%2Freact-hooks%403.0.0 |
@sijad Oh wow, what a coincidence 🙂. Thanks! |
fixes #74