-
-
Notifications
You must be signed in to change notification settings - Fork 929
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] useContractReads data instability #648
Comments
Off chance this might be related TanStack/query#3772 |
Might be useful to look at for this one: https://github.com/Uniswap/redux-multicall/blob/main/src/hooks.ts#L55 |
Opened a fix here: #659. React Query's data comparison function does not support the ethers |
That makes sense, feels like this would be a valuable PR to ethers too now I think about it. I wonder if the same is true for ethers v6. Yeah, it seems this would work, but would like to test if you'd put up a pre-release version. I'd be happy to do that if you can. |
@matthewlilley – can you check |
This issue has been locked since it has been closed for more than 14 days. If you found a concrete bug or regression related to it, please open a new bug report with a reproduction against the latest wagmi version. If you have any other comments you can create a new discussion. |
Is there an existing issue for this?
Package Version
latest
Current Behavior
useContractReads returns unstable data, equality is always lost despite underlying data being exactly the same
Expected Behavior
In cases where the underlying data has not changed, for equality to be preserved.
Steps To Reproduce
repro below
Link to Minimal Reproducible Example (CodeSandbox, StackBlitz, etc.)
https://codesandbox.io/s/small-smoke-2i7b0q?file=/src/App.js
The text was updated successfully, but these errors were encountered: