Newest react dev tools doesnt render state anymore
sanderha opened this issue · comments
I'm using this package which works great! I'm using it like this for example:
createStore({
name: 'apiDataStore',
state: {
projects: []
}
});
And then somewhere in a component like this:
const [state] = useStore('apiDataStore');
If I want to set anything, I can do this:
const [state, setState] = useStore('apiDataStore');
This works great. And it also used to be rendered fine by the React dev tools (nextState etc). After the newest update to the dev tools though, it just says "Loading hooks..." forever, in the spot where state used to be displayed.
A lot of components now also have an attribute on them: staticContext: undefined
Any ideas?
Hey @sanderha, thanks for reporting the issue. I'll take a look at it and provide some feedback soon.
@sanderha I confirmed this is an issue with react devtools with hooks in general. even when im not using the library, useState also causes the same issues. Couldn`t find an issue talking about this specifc problem over there, though. Can you confirm this happens with hooks in general and not only react-hookstore in your env?
I'll close this issue since it is inactive
Hey sorry about not responding.
Yeah using the example from https://reactjs.org/docs/hooks-state.html behaves the same with the react dev tools
No problem, @sanderha. I wish I was able to help you but since it's a problem with react hooks in general, I recommend you opening an issue to react-devtools repository (if no one has done it yet)