[PreSale Question] KeyWord spliting for individual link

Hi there, currently my index have a field “tags” where all my keyword are stored with a separator.

If i use the autocomplete feature iv’e got as a result the whole content of the field, not each key word separatly so i can’t make individual new “simple” search links on each keyword.

What is the startegy to achieve this, do i need to index those keywords as an array? is there a built in function to do this? do i need to split the result by my self? another way to do it that i didn’t see in the documentation?
thks by advance

Hi @jeanlouis,

Are you using autocomplete.js?

Tags could definitely be an array. It’ll be returned by Algolia. Then when choosing what to display, you could iterate on this array and display your tag as links.

Here’s an example of autocomplete.js => https://www.algolia.com/doc/tutorials/search-ui/autocomplete/auto-complete/#snippet_javascript

Let’s say you have a “tags” array on your record, then you could access it with suggestion._highlightResult.tags.

Does that helps?

Bonjour Marie Laure, merci pour votre réponse,
Yes i use autocomplete.js for now,

Ok, so i need to “split” the array by myself, there’s no function do do this by default.
Have a nice day.