Query runs a search query.
client.query({ variables: { q: "<search query>" } })
.then((response) => {
// handle response
})
.catch(error => {
// handle error
})
Track events against the current queryId
name of event to track (e.g. click, add_to_cart, purchase)
unique result identifier (e.g. product sku)
key/value pair of information relevant to the event
Track events against a specific current queryId
queryId that event should be tracked against
name of event to track (e.g. click, add_to_cart, purchase)
unique result identifier (e.g. product sku)
key/value pair of information relevant to the event
Update the current queryId
queryId that events calling track should be tracked against
Generated using TypeDoc
SearchIOAnalytics is a utility class for tracking and sending Search.io events. Event data is persisted to localStorage before being sent to track how users use search results and/or move through an ecommerce purchase funnel.