useStoreRehydrated always returning true?
See original GitHub issueFor some reason useStoreRehydrated returns true even though it isn’t.
I’m using
const isRehydrated = useStoreRehydrated();
console.log('isRehydrated', isRehydrated);
if (!isRehydrated) return null;
to protect the App from loading until state is rehydrated.
But this console logs isRehydrated true even on the first run and I can see the App render with empty data and then rerender with rehydrated data a second later.
Not sure what to check next. Thanks for any help!
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (1 by maintainers)
Top Results From Across the Web
useStoreRehydrated always returning true? - - Bountysource
For some reason useStoreRehydrated returns true even though it isn't. I'm using const isRehydrated = useStoreRehydrated(); console.log('isRehydrated', ...
Read more >Initial store data is components is always null , then loads + re ...
We are having a similar issue. When the size of the stored items increased above 5-6mb useStoreRehydrated this hook returns true before the ......
Read more >useStoreRehydrated - Easy Peasy v5
import { useStoreRehydrated } from 'easy-peasy'; ... function App() { const rehydrated = useStoreRehydrated(); return ( <div> <Header ...
Read more >Rehydration of store not working with redux-persist in react ...
Rehydration of redux-persist is not working for an unknown reason. Here is my config: const persistConfig = { key: 'root', ...
Read more >Vegetarian friendly state for React | Frontend Utils library - kandi
returns a function that is used to store state ... setLoading(true) store.dispatch.reset(newState) store.dispatch.setLoading(false)
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Would be great if you could provide a repro. ♥️
Sorry we had to close old issues with inactivity in a movement towards centring ourselves with what is priority for the community. 👍
Thanks for your input! Good to see that the
useStoreRehydratedhook works as expected now 🎉Thanks for taking the time - appreciate it 👍