diff --git a/src/pages/Home.js b/src/pages/Home.js index 41f894c..d99b1fb 100644 --- a/src/pages/Home.js +++ b/src/pages/Home.js @@ -1,3 +1,42 @@ +import Row from 'react-bootstrap/Row'; +import Col from 'react-bootstrap/Col'; +import Container from "react-bootstrap/Container"; +import Card from "react-bootstrap/Card"; + +import { useState, useEffect } from "react" + export function Home ( props ) { - return (

{props.greeting}

) + const [ books, setBooks ] = useState([]) + + useEffect( () => { + setBooks( props.items ) + console.log( props.items ) + },[props.items]) + + // collection + const Items = books.map( (item, key) => { + return ( + + + + {item.book_title} + + By {item.author} + + + + + + ) + }) + + + return ( + + + {Items} + + + + ) } \ No newline at end of file