diff --git a/pages/blog/index.page.tsx b/pages/blog/index.page.tsx index fca113153..ed03e226e 100644 --- a/pages/blog/index.page.tsx +++ b/pages/blog/index.page.tsx @@ -50,6 +50,7 @@ export async function getStaticProps({ query }: { query: any }) { slug, frontmatter, content, + readingTime: Math.ceil(readingTime(content).minutes), }; }); @@ -196,6 +197,7 @@ export default function StaticMarkdownPage({ const [currentPage, setCurrentPage] = useState(1); const totalPages = Math.ceil(sortedFilteredPosts.length / POSTS_PER_PAGE); + const isFirstPage = currentPage === 1; useEffect(() => { if (currentPage > totalPages) { @@ -319,27 +321,26 @@ export default function StaticMarkdownPage({ {/* Blog Posts Grid */}