Shopping cart
@@ -51,7 +51,11 @@ export default function Cart({ open, setOpen, cart, updateCart }) {
-
+ {cart.length == 0 &&
+
+
+ Your Cart is Empty.
+
}
diff --git a/src/Components/ProductTable.jsx b/src/Components/ProductTable.jsx
index ea76621..4bcff02 100644
--- a/src/Components/ProductTable.jsx
+++ b/src/Components/ProductTable.jsx
@@ -41,7 +41,7 @@ export default function ProductTable({ cart, updateCart }) {
setProducts(body);
};
fetchProducts();
- });
+ }, []);
return (