Duplicate requests with instantsearch and useRefinementList hook #5953
Labels
Library: React InstantSearch ≥ 7
Issues in any of the react-instantsearch@7 packages (formerly named react-instantsearch-hooks)
🐛 Current behavior
Instantsearch sends multiple duplicate requests to fetch results and it seems to happen with this component mostly in instantsearch using the useRefinementList() hook. Does anyone know how to fix this because I've tried just about everything. Thanks!!
🔍 Steps to reproduce
Add useRefinementList into a component and have multiple components with the instantsearch context. It will perform a fetch for each component with an identical request. After page is loaded, all requests are normal and singular.
Live reproduction
codesandbox.io
💭 Expected behavior
No duplicate requests when loading the page.
Package version
react-instantsearch 7.4
Operating system
No response
Browser
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: