Advertisement
emanuel1109

theplantmother - view item

Apr 20th, 2022
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. window.dataLayer = window.dataLayer || [];
  2. window.dataLayer.push({
  3.   event: 'view_item',           // name of the event. In this case, it always must be view_item
  4.   ecommerce: {                          
  5.     items: [{                           // an array with a product
  6.       item_name: 'Product 1',           // insert an actual product name
  7.       item_id: 'product1',              // insert an actual product ID / SKU
  8.       currency: 'USD', // leave it static as the website only works on USD
  9.       price: '11.99',                   // insert an actual product price. Number or a string. Don't include currency code
  10.       item_category: 'gloves',         // insert an actual product top-level category
  11.       quantity: '1'                     // product quantity. In this case, it will usually be equal to 1
  12.     }]
  13.   }
  14. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement