I think we should either support or throw an exception when using an array of string for the hosts option:
const searchClient = algoliasearch("", "", {
hosts: ["test.com"]
});
instead of
const searchClient = algoliasearch("", "", {
hosts: [{ url: "test.com/sitesearch" }]
});
Today it's creating a weird "undefined" domain.