swr
swr copied to clipboard
reValidateOnMount doesn't work when component is unmounted while the data is being fetched
Bug report
Description / Observed Behavior
Unmounting the component while the data is being fetched i.e; isValidating
is true, doesn't trigger refetch on the next mount, even if reValidateOnMount
is set to true.
Expected Behavior
Refetch should happen on each mount if reValidateOnMount
is set to true.
Additional Context
- Version: 0.5.6
- Framework: React Native
@sibasishm Could you reproduce it on CodeSandbox? Updating the SWR version might fix your issue.