Category filter is not applied by InstantSearchNext when the url is opened via next/link #6359
Open
1 task done
Labels
triage
Issues to be categorized by the team
🐛 Current behavior
We are using InstantSearchNext to make SSR for Algolia search.
The category is parsed from the url and passed to the uiState
We have a component that has
useMenu
hook. It's visible when the page is opened via<a href="/categoryId">Category</a>
But when the page is opened via next/link
<Link href="/categoryId">Category</Link>
so that transition is seamless we got warning that menu widget is absent and the category parameter is ignored so we retrieve all the products.The issue is reproduced when
useDynamicWidgets
is used together with useMenu is another component🔍 Steps to reproduce
Live reproduction
https://codesandbox/no-sandbox
💭 Expected behavior
CSR page to return the same result as SSR. All filters that have been set up by routing prop of the InstantSearchNext component are applied.
Package version
algoliasearch 4.24.0, react-instantsearch 7.13.0, react-instantsearch-nextjs 0.3.10
Operating system
macOS 14.5
Browser
Chrome Version 128.0.6613.120
Code of Conduct
The text was updated successfully, but these errors were encountered: