Next Commerce
Data AttributesDisplay

Display Paths

Display paths are the values you can pass to data-next-display. They are grouped into namespaces — cart.*, package.*, campaign.*, order.*, profile.*, selection.* — each backed by a different store.


Cart

Live values from the cart.

PathDescriptionExample output
cart.totalGrand total$99.99
cart.subtotalSubtotal before shipping/tax$89.99
cart.shippingShipping cost$10.00
cart.taxTax amount$8.00
cart.discountDiscount amount$10.00
cart.totalQuantityTotal units in cart5
cart.itemCountDistinct line items3
cart.currencyActive currency codeUSD
cart.isEmptyEmpty state booleantrue / false
<span data-next-display="cart.total">$0.00</span>
<span data-next-display="cart.totalQuantity">0</span>

For a complete cart-aware UI, use Cart Summary — it documents every cart attribute alongside templates and reference tables.


Package

Live values for a specific package. Use package.[id].<property> where [id] is the package's ref_id.

PathDescription
package.[id].namePackage display name
package.[id].imageImage URL
package.[id].pricePer-unit price
package.[id].price_totalTotal package price
package.[id].price_retailRetail (compare-at) per-unit price
package.[id].savingsAmountTotal savings
package.[id].savingsPercentageSavings as percentage
package.[id].hasSavingsBoolean — has savings
package.[id].isBundleBoolean — is multi-pack
package.[id].qtyUnits in the package (for bundles)
package.[id].intervalSubscription interval (month, day)
package.[id].interval_countNumber of intervals per cycle
package.[id].is_recurringBoolean — is subscription

For shorthand syntax inside a parent with data-next-package-id, see Package Display.

For the full property list (including discount-context properties that require an active cart), see Reference → Attributes.


Campaign

Campaign-level data loaded once on init.

PathDescription
campaign.nameCampaign name
campaign.currencyActive currency code
campaign.languageActive language code

See Campaign Attributes for the dedicated reference.


Order

Live order data on post-purchase pages where ?ref_id= has loaded an order.

PathDescription
order.totalGrand total
order.subtotalSubtotal
order.shippingShipping cost
order.taxTax amount
order.refIdOrder reference ID
order.numberHuman-readable order number
order.customer.nameCustomer full name
order.shippingAddress.fullPre-formatted address

See Order Data for every order property.


Profile

Currently active customer profile.

PathDescription
profile.activeActive profile ID
profile.existsBoolean — a profile is active

For conditional display by profile, use the dedicated data-next-show-if-profile / data-next-hide-if-profile attributes — see State → Reference → Attributes.


Selection

Currently selected card in a data-next-cart-selector container with a data-next-selector-id.

PathDescription
selection.<id>.nameSelected package name
selection.<id>.pricePer-unit price
selection.<id>.totalTotal price (price × quantity)
selection.<id>.savingsAmountCalculated savings
selection.<id>.hasSelectionBoolean — at least one card is selected

See Selection for every property.


Raw Numeric Values

Append .raw to a numeric path to get the underlying number rather than a formatted string. Required when the value is the input to a math operator.

<!-- 10% of total -->
<span data-next-display="cart.total.raw"
      data-multiply-by="0.1"
      data-format="currency">$9.90</span>

Available on most numeric paths: cart.total.raw, package.[id].price.raw, order.total.raw, selection.<id>.total.raw, etc.


Combining Paths and Math

Display paths can be the input to inline math operators like data-multiply-by, data-divide-by, data-add, data-subtract. See Configuration → Math.

<!-- Discount as % of subtotal -->
<span data-next-display="cart.discount"
      data-divide-by="cart.subtotal"
      data-multiply-by="100"
      data-format="percentage">10%</span>

Next Steps

On this page