Next Commerce
Data AttributesCampaignReference

Attributes

Campaign-level data is exposed under the campaign.* namespace and bound via data-next-display.

Properties

PathTypeDescription
campaign.namestringCampaign display name
campaign.currencystringISO 4217 currency code (e.g., USD, EUR)
campaign.languagestringISO 639-1 language code (e.g., en, es)

Notes

  • Campaign data loads on SDK init and is read-only — you cannot mutate it from HTML attributes.
  • Properties are also accessible from conditionals: data-next-show="campaign.language == 'en'".
  • For the full campaign object including packages and offers, use useCampaignStore.getState().data from JavaScript.

On this page