Zendesk InstantSearch: Overriding widget templates to add missing accessibility attributes, not working

We’re using the algolia search for zendesk. We’ve had an accessibility review and the algolia instantsearch widget is missing some critical attributes and information for accessibility.

So as a result we would like to override the component templates, but am having trouble getting it to work.

  algoliasearchZendeskHC({
    applicationId: 'YYYYYYYY',
    apiKey: 'YYYYYYYYYYYYYYYYYY',
    subdomain: 'mysite',
    poweredBy: false,
  	color: '#3e3e44',
  	highlightColor: '#3e3e44',
    instantsearch: {
      hitsPerPage: 10,
    },
  	templates: {
      autocomplete: {},
      instantsearch: {
  			hit: `<div>Hello World</div>`,
  		}
    },
  });

But I do not see Hello world in our search results. What am I doing wrong?

Thanks

1 Like