Skip to main content

common

Enumerations

EnumerationDescription
COMMON_SDK_EVENTS-
REVIEWS_WIDGET_NAMES-
REWARDS_WIDGET_NAMES-
WISHLIST_WIDGET_NAMES-

Classes

ClassDescription
ModalClosedSdkEventEvent detail for modalClosed event.
ModalOpenedSdkEventEvent detail for modalOpened event.
WidgetClosedSdkEventEvent detail for widgetClosed event.
WidgetInjectedSdkEventEvent detail for widgetInjected event.
WidgetOpenedSdkEventEvent detail for widgetOpened event.

Interfaces

InterfaceDescription
CustomURLsBuilderInterface-
ModifyURLFunctionA function type for modifying URLs within the SDK. Takes a URL string as input and returns a modified URL string.

Type Aliases

Type AliasDescription
ModalToken-

Functions

FunctionDescription
setCustomURLsBuilderThe setCustomURLsBuilder method allows you to provide custom URL builders for product, collection, and login pages. Use this on custom storefronts where Shopify's standard URL structure (/products/<handle>, /collections/<handle>, /account/login) does not apply.
setGlobalProductIdThis method sets a global product ID to be used as a fallback when a widget requires a product ID but none is provided. Using a global product ID ensures consistent behavior across widgets that depend on product-specific data.
setGlobalVariantIdThis method sets a global variant ID to be used as a fallback when a widget requires a product variant ID but none is provided. Using a global variant ID ensures consistent behavior across widgets that depend on variant-specific data.
setModifyURLFunctionThe setModifyURLFunction method allows you to define a custom function to modify URLs within the SDK. This can be useful for adding query parameters, changing paths, or any other URL transformations needed for your application.