Shopify Dawn Theme Hide/Disable Add to Cart Popup

  1. Open theme code
  2. Online Store > Themes > Action > Edit code
  3. Find a file called cart-notification.js under the Assets category

Shopiy Dawn Theme Edit Code Screenshot

  1. Find following lines of code
renderContents(parsedState) {
      this.cartItemKey = parsedState.key;
      this.getSectionsToRender().forEach((section => {
        document.getElementById(section.id).innerHTML =
          this.getSectionInnerHTML(parsedState.sections[section.id], section.selector);
      }));
      if (this.header) this.header.reveal();
      this.open();
  }
  1. Comment out two lines that trigger the opening of the popup by enclosing them in /* and */
  2. It should look like this
renderContents(parsedState) {
    this.cartItemKey = parsedState.key;
    this.getSectionsToRender().forEach((section => {
      document.getElementById(section.id).innerHTML =
        this.getSectionInnerHTML(parsedState.sections[section.id], section.selector);
    }));
  /*
	if (this.header) this.header.reveal();
  this.open();
	*/
}
  1. Save the code
  2. Refresh the product page.
  3. Try adding a product to the cart, the popup will not open.