Skip to content
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

useLazyQuery ignores request if one is in progress (or how to cancel running requests) #213

Open
dominictobias opened this issue Sep 13, 2019 · 0 comments

Comments

@dominictobias
Copy link

dominictobias commented Sep 13, 2019

Hi,

I'm using useLazyQuery for a user lookup for suggestions, so it's important that requests aren't missed.

The default behaviour it seems is that requests are ignored if one is happening - I would like to cancel running requests and fire the new one.

At the moment if I type "Dominic Tobiaz" and then correct it to "Dominic Tobias", the request will be ignored if the misspelled one is still running.

The useLazyQuery request function sadly is not returning the fetch Promise for me to be able to cancel, nor have I had any luck with fetchPolicy: 'network-only'.

Thanks for any help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant