Skip to content

Search API twig extension with Faceting #208

@DiegoPino

Description

@DiegoPino

What (but most important why) ?

Search API is powerful and we can use Views + facets to do a lot. But there is a big limitation (core) that we can not get around. Facet blocks are cached and even if a single View is called 3 or more time in a page, facets will only act on the First Views call making dynamic faceting based on arguments impossible.

What I want is a simple Twig extension that takes an index, a list of field, a search token against those and what to facet, then returns facets but as pivoted hierarchies. This way we can programmatically add multiple facets (rendered in twig) and build interesting displays.

Metadata

Metadata

Assignees

Labels

Drupal 9Everyone's favorite version until Drupal 10 comesTwigTwig template processingTwig ExtensionMake those flowers reach the sunenhancementNew feature or request

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions