Closed rishankHashout closed 2 years ago
Using Hooks, you should be able to create a stable objectID based on your criteria instead of the current logic: https://community.algolia.com/jekyll-algolia/hooks.html#before-indexing-each
the stable objectID work well when content of page is changed , but as we have frequent insertion and deletion of pages the same issue is encountered.
Could you explain what the ideal solution would be? if the content is changed, I'm not sure how the objectID can be stable to be pinned. What condition do you want to pin on?
i want to pin the record which is from particular url , as we want to show this url in results on empty query but when the content is changed in that url the object id is changed and it doesn't work as expected.
Instead of pinning, you could do optional filtering if the query is empty: https://www.algolia.com/doc/guides/managing-results/rules/merchandising-and-promoting/how-to/how-to-promote-with-optional-filters/ That way you only need a stable attribute, not stable objects completely. Hope that helps!
yes , that worked Thank you
hey , I am using algolia's rules where I pin the objects ids of specific url. But if the content on that page is changed the object id is delete and rules does not works. How to tackle this problem ? Thanks