Getting Started
How the Script Loads
The window.shoplift Object
window.shoplift Objectinterface ShopliftPublic {
isHypothesisActive(hypothesisId: string): Promise<boolean>;
setAnalyticsConsent(consent: boolean): Promise<void>;
getVisitorData(): ExternalVisitorData;
}
declare global {
interface Window {
shoplift?: ShopliftPublic;
}
}Method
Purpose
Returns
Async
Quick Start

Safely Checking for Shoplift
When to Use the JavaScript API
Last updated
Was this helpful?