I have simple test aplication in pure html and javascript with CDN. My test code just copied from source example on angolia site. It looks like this:
autocomplete({
container: `#autocomplete`,
placeholder: "Search",
getSources() {
return [
{
// ...
templates: {
item({ item, components, html }) {
return html`<div>
<img src="${item.image}" alt="${item.name}" />
<div>
${components.Highlight({ hit: item, attribute: 'name' })}
</div>
</div>`;
},
},
},
];
},
});
The seatch is working fine but
components.Highlight
function is not workin. No any error just it doesn't highlight matched search results... P.S I do not use algolia search engine. Just autocomplete functionality.