Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
setTimeout(() => {

  const przWidget = document.getElementsByClassName('preezie-widget-app')[0]

  if(przWidget) {

    przWidget.addEventListener('przAddToCartEvent', (event) => {

        // event: { detail: { productIdid: '125173761', quantity: 1 } }

        // add your custom "add to cart" events here

    })

  }          

}, 2000);

...