A message is published to this topic when all the regions and widgets on a page are loaded.
$.Topic(PubSub.topicNames.PAGE_READY).publish(pageEventData);
Arguments
pageEventData
: A JavaScript object that includes data about the loaded page, for example:
{ pageId:"category", contextId:"cat60041", seoslug:" psychological-thrillers" previousContextId: null, pageRepositoryId: "categoryPage" }
The properties in the JavaScript object include:
pageId
: An identifier for the page requested that represents either the page type (for example,product
,collection
,home
, and so on) or, for article pages, the page address that has been assigned in the Layout settings (for example,aboutUs
,shipping
, orreturns
, are all pages of typearticle
).contextId
: For contextual pages, acontextId
is included and it may be a product ID, category ID, an order ID, or an order confirmation ID. To determine the ID for a specific product or category, you can view the item’s details on the Catalog page in Commerce Cloud. Order and order confirmation IDs are system-generated and cannot be known beforehand but you can check for their existence in the JSON object.seoslug
: An SEO-friendly, internally-generated name for the product or category, based on the product or category name. This property only has a value when changing to a product or category page.previousContextId
: The context ID, if one exists, for the page that was rendered before thePAGE_CHANGED
event occurred.pageRepositoryId
: The identifier for the page in the page repository. For the out of the box pages, this value can behomePage
,categoryPage
,profilePage
,checkoutPageWithGiftCard
,userSpacesPage
,orderHistoryPage
,orderDetailsPage
, oruserSpacesSettingsPage
. For any additional pages created in Commerce Cloud, a system-generated ID is created, for example,pa100001
.
Memory enabled
Yes