-
-
Save duhaime/d1190bc65ef55a38ef043cfae704744b to your computer and use it in GitHub Desktop.
Algolia Minimal
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import algoliaClient from "algoliasearch/lite" | |
window.client = algoliaClient( | |
'latency', | |
'6be0576ff61c053d5f9a3225e2a90f76' | |
) | |
window.result = window.client.multipleQueries( | |
[{ | |
indexName: 'instant_search', | |
query: 'headphones', | |
params: { | |
hitsPerPage: 3, | |
} | |
}, { | |
indexName: 'instant_search_price_desc', | |
query: 'headphones', | |
params: { | |
hitsPerPage: 2, | |
//filters: '_tags:promotion' | |
} | |
}] | |
) | |
window.result.then(r => { | |
console.log(' * got result', r) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment