0

I'm trying to use slate's _hideCartPopup and _showCartPopup to respond to onclick on the cart's anchor tag. I'm using the latest debut theme.

tried with this but I'm having error..

 var siteheadercar = document.querySelector('.site-header__cart');
 siteheadercar.addEventListener('click', function() {
     theme.Product._showCartPopup();
 });

Uncaught TypeError: theme.Product._showCartPopup is not a function

Christian Young
  • 543
  • 3
  • 8
  • 19
  • are you sure, there is code related to popup into theme already? – Onkar Jul 13 '21 at 04:59
  • @Onkar yes I am.. https://help.shopify.com/en/manual/online-store/themes/os/themes-by-shopify/debut/settings#add-to-cart-notification .. However, I want to extend the functionality by making it a popup cart.. figured I could use the show/hide popup function to do that – Christian Young Jul 13 '21 at 18:05

0 Answers0