contextData and contextDataRequest Properties

  • contextData is a property of every view, but it is only populated with data in some of those views.
  • contextDataRequest is a property available to views that are children of views with contextData. You can call contextDataRequest by passing in an array of types of data you want returned.

Views can return four types of objects and each view may support multiple object types. The object types that a view can return is specific to each view class. However, most views do not support requests.

When requests are supported and a data object is returned, its values are specific to the view instance. For example, if you are working on a product details page (PDP), contextData potentially supports requests for the product and item model. Whether contextData supports requests for both the product and item model, or just one of those models, depends on the particular product page the user is viewing.

The following table lists the parent view classes that have contextData properties and also lists the types of data that they can provide to child views.

Leave a comment

Your email address will not be published. Required fields are marked *