To add your own search parameter to your Shopify site, you can use the configure widget in your Shopify front end.
If you are making your own custom InstantSearch implementation, you can add the
configure widget with your search parameter there.
Otherwise, you can find the configure widget in your algolia_instant_search.js.liquid file in your theme files and add your search parameter:
instant.search.addWidgets([
configure({
hitsPerPage: instant.hitsPerPage,
clickAnalytics: true,
// add your search parameter
}),
]);
Please note that if you do decide to make changes to your algolia_instant_search.js.liquid that this file will be overwritten if you re-install Algolia on your theme.
You should also check that any added configuration is not overridden by any other InstantSearch configuration code present in your algolia_instant_search.js.liquid file.
Last reviewed 25-04-22.