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

[BUG?] Inconsistent value while doing conditional rendering. #387

Closed
eip1599 opened this issue May 11, 2020 · 1 comment · Fixed by #794
Closed

[BUG?] Inconsistent value while doing conditional rendering. #387

eip1599 opened this issue May 11, 2020 · 1 comment · Fixed by #794
Labels
bug Something isn't working

Comments

@eip1599
Copy link

eip1599 commented May 11, 2020

I am doing conditional rendering. So when the data is not ready I don't show children.

Expected behavior:
Consistent value across components regardless of conditional rendering.

Current behavior:
Value update is not synchronized, previous value is shown in Children.

Minimal reproduction:
https://codesandbox.io/s/swr-mutate-bug-uryb6
When you click into the mutate button twice, you see inconsistent values in the console.

@eip1599 eip1599 changed the title Inconsistent value while doing conditional rendering. [BUG?] Inconsistent value while doing conditional rendering. May 18, 2020
@shuding shuding added the bug Something isn't working label Jun 6, 2020
@roy-eth-dev
Copy link

Is this issue confirmed and going to be touched in some near future?
Or do you recommend migrating to react-query, seriously?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants