htmlintermediatemit
Product Card
An e-commerce product card with add-to-cart.
3.9k1.8k73080
About this module
A product card with image, name, price, rating and a quick add-to-cart button — ready for storefronts.
#card#product#ecommerce
Source code
Installation
- 1
Create the files
Create `index.html` and `style.css` in the same folder.
- 2
Paste the code
Copy each file's source into its matching file.
- 3
Open in the browser
Open `index.html` in any modern browser.
Usage
- 1
Copy the HTML
Paste the card markup where you need it.
<link rel="stylesheet" href="style.css" /> <article class="mh-product"> <div class="mh-thumb"> <span>NORDIC MUG</span> </div> <div class="mh-body"> <h3>Nordic Ceramic Mug</h3> <div class="mh-stars" aria-label="Rated 4.8 out of 5">★★★★★ <span>4.8</span></div> <div class="mh-row"> <span class="mh-price">$18</span> <button class="mh-add">Add to cart</button> </div> </div> </article>