mirror of
https://gitea.smigz.com/smiggiddy/odin-codeprojects.git
synced 2025-07-16 22:30:37 -04:00
adding more logic and components
This commit is contained in:
parent
9a7596b2a8
commit
da6d76e598
10 changed files with 109 additions and 83 deletions
|
@ -1,6 +1,6 @@
|
|||
import Product from "./products";
|
||||
import { Link } from "react-router-dom";
|
||||
import Products from "./products";
|
||||
import PropTypes from "prop-types";
|
||||
|
||||
import styles from "./productCollection.module.css";
|
||||
|
||||
export default function ProductCollection({ loading, items, cart, setCart }) {
|
||||
|
@ -9,7 +9,10 @@ export default function ProductCollection({ loading, items, cart, setCart }) {
|
|||
{!loading
|
||||
? items.map((item, index) => {
|
||||
return (
|
||||
<Product item={item} key={index} cart={cart} setCart={setCart} />
|
||||
<div key={index} className={styles.card}>
|
||||
<Products item={item} cart={cart} setCart={setCart} />
|
||||
<Link to={item.id}> More Info</Link>
|
||||
</div>
|
||||
);
|
||||
})
|
||||
: null}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue