Skip to main content

Global Objects

We created a few objects to help with using the correct terms inside the SDK:

  • you can import them when using npm/yarn
  • they will also be bound to window

Single Page / Multi Page

const FastSimonAppType = {
SinglePage: "SPA",
MultiPage: "MPA"
};

Reporting Events

const FastSimonEventName = {
AutocompleteProductClicked: "instantsearch-product",
AutocompleteCategoryClicked: "instantsearch-category",
AutocompletePopularClicked: "instantsearch-popular-search",
SearchPerformed: "search",
SmartCollectionPreformed: "collection",
SerpProductClicked: "productFromSearch",
CollectionProductClicked: "productFromCollection",
RecommendationProductClicked: "productFromRecommendation",
LookALikeClickedSerp: "lookALikeViewSerp",
QuickViewClickedCollection: "quickViewCollection",
LookALikeClickedCollection: "lookALikeViewCollection",
QuickViewClickedSerp: "quickViewSerp",
LookALikeProductClicked: "productFromLookALike",
QuickViewProductClicked: "productFromQuickView",
DirectProductClicked: "productDirect",
CartVisited: "cartVisited",
AddToCartPerformed: "cartPerformed",
};

Sort Options ID's

const FastSimonSortBy = {
PriceHighToLow: "price_max_to_min",
PriceLowToHigh: "price_min_to_max",
NewFirst: "creation_date",
OldFirst: "creation_date_oldest",
Popularity: "popularity",
Reviews: "reviews",
AtoZ: "a_to_z",
ZtoA: "z_to_a",
relevancy: "relevency"
};

Recommendation Specs

const FastRecommendationsSource = {
relatedRecentProducts: "related_recent_products",
relatedPurchase: "related_purchase",
relatedViews: "related_views",
relatedCart: "related_cart",
similarProducts: "similar_products",
relatedRecentlyViewed: "related_recently_viewed",
similarProducts_byAttributes: "similar_products_by_attributes",
similarProductsLookalike: "similar_products_lookalike",
relatedTopProducts: "related_top_products",
};