The pros :
Allows user to show category - sub category filter system that would be useful for customers to get data.
The cons:
WordPress by default does not distinguish category levels. What does this mean ?
WordPress records Parent for a category but - it does not by default save which level a category is.
So for example a category - sub category system like Clothing > Men > T-shirts
Here, Clothing is level 1 - Men is level 2 - T shirts is level 3.
However the Categories are not stored in WordPress with these levels associated with them.
So when a post is indexed - these calculations need to be made , so we would have to get the highest parent of the category tree
For 3 or less levels this should be fine - BUT - for larger nesting of categories - this would be quite resource intensive.
A possible solution for now is to allow users to implement this system but with the warning of the associated risk.
I am of the opinion that since this could potentially crash / consume large resources in some use cases - it would not be a good idea to provide this as a configurable option on the product for now - rather we should provide code samples that allow this to be implemented.
Feature request : Allow use of Hierarchal menu for Instant Search : https://www.algolia.com/doc/api-reference/widgets/hierarchical-menu/js/
The pros : Allows user to show category - sub category filter system that would be useful for customers to get data.
The cons: WordPress by default does not distinguish category levels. What does this mean ? WordPress records Parent for a category but - it does not by default save which level a category is.
So for example a category - sub category system like Clothing > Men > T-shirts Here, Clothing is level 1 - Men is level 2 - T shirts is level 3. However the Categories are not stored in WordPress with these levels associated with them. So when a post is indexed - these calculations need to be made , so we would have to get the highest parent of the category tree For 3 or less levels this should be fine - BUT - for larger nesting of categories - this would be quite resource intensive.
A possible solution for now is to allow users to implement this system but with the warning of the associated risk.
I am of the opinion that since this could potentially crash / consume large resources in some use cases - it would not be a good idea to provide this as a configurable option on the product for now - rather we should provide code samples that allow this to be implemented.