Cover photo by Tim Wildsmith on Unsplash https://res.cloudinary.com/practicaldev/image/fetch/s--EakxJphR--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xixndwapir6nng9la3qe.png I only have 7 months of an intensive bootcamp for Full stack web developer on my back.
"Focus on learning the basic logic structures of the languages and frameworks, the rest is just syntax."
#second Second: do the same for the initial state of the page displaying the posts page variable, by setting it to 0.
And here is the overview of all of this logic: //// pagination //// const [posts] = useState(props.posts); const [page, setPage] = useState(0); const postsPerPage = 3; const numberOfPostsVisited = page * postsPerPage; const totalPages = Math.ceil(posts.length / postsPerPage); const changePage = ({ selected }) => { setPage(selected); }; //// pagination ////