I set a search client with the Algoliasearch package with my Aloglia app ID and search API key. And also supply a response cache params for it. Then, provide it to React InstantSearch for use:
After setting it, it makes a cache response to a browser localStorage within the timeToLive duration. However, when I type in a URL with facet params that worked before (mapping the route to state), the route to state does not work. It will remove all the facet params, e.g. I have a url with facet param,?onsale=20%3A100. After going to the page, the param will be removed if it is within a cache duration (a prefetch is fine).
I am trying to integrate query request caching into my Nest.js application by referencing: https://www.algolia.com/doc/api-client/getting-started/customize/javascript/?client=javascript#caching-requests-and-responses.
I set a search client with the Algoliasearch package with my Aloglia app ID and search API key. And also supply a response cache params for it. Then, provide it to React InstantSearch for use:
After setting it, it makes a cache response to a browser localStorage within the timeToLive duration. However, when I type in a URL with facet params that worked before (mapping the route to state), the route to state does not work. It will remove all the facet params, e.g. I have a url with facet param,?onsale=20%3A100. After going to the page, the param will be removed if it is within a cache duration (a prefetch is fine).
Is there any way to fix it? Thanks.
packages version: