addToCart
Add to cart is a common ecommerce action that allows a shopper to place a selected product, and optionally a chosen variant and quantity, into a persistent shopping cart for later checkout. The term may refer to a button, link, or other control labeled Add to cart on product detail pages.
When a user activates Add to cart, the system creates or updates a cart object associated with
Common data captured with the action includes product ID, variant ID, requested quantity, price, and stock status.
Design considerations include the visibility and labeling of the button, accessibility via keyboard and screen readers,
Analytics typically track add-to-cart events for conversion and funnel analysis, with localization and tax/shipping rules influencing