In this help article, we will show you two ways on how to add or edit fields to the Elevar dataLayer
Add or Edit the Elevar dataLayer through:
- Snippet for the Thank you Page
- Snippets for Other Pages
To access the Elevar dataLayer snippet for the thank you page, you can go to Settings > Checkout in Shopify and make any edits you need in the Additional Scripts box.
If you want to edit the dataLayer for other pages of the site, go into your theme and click "Edit code". Search for "elevar", and this should return 2 snippets (3 if you are on Shopify plus). The dataLayer snippets are found in the "elevar-body-end" file (and in the "elevar-checkout-end" file if on Shopify Plus).
There, you can edit any fields or add additional fields as you need. Here is a link to Shopify's liquid objects - this will detail what Shopify variables you can use and what they return.
Hope this helps!