algolia / instantsearch

⚡️ Libraries for building performant and instant search and recommend experiences with Algolia. Compatible with JavaScript, TypeScript, React and Vue.
https://www.algolia.com/doc/guides/building-search-ui/what-is-instantsearch/js/
MIT License
3.73k stars 527 forks source link

fix(RawHtml): force component to remount #6254

Closed aymeric-giraudet closed 5 months ago

aymeric-giraudet commented 5 months ago

Summary

This fixes https://github.com/algolia/instantsearch/pull/6243#discussion_r1649444124

Result

We didn't see that with Hits because all templates remount regardless, as they are not memoized. There might be a way to solve this only with componentDidUpdate but I think there would be more duplicate code, probably fine to keep as is until we get rid of Hogan.

codesandbox-ci[bot] commented 5 months ago

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 4e6c341dd5f84a76101a1d00093f657521974ebd:

Sandbox Source
example-instantsearch-getting-started Configuration
example-react-instantsearch-getting-started Configuration
example-react-instantsearch-next-app-dir-example Configuration
example-react-instantsearch-next-routing-example Configuration
example-vue-instantsearch-getting-started Configuration
aymeric-giraudet commented 5 months ago

Just added one @Haroenv