jolbol1 / nextjs-velite-blog-template

A static blog template built using NextJS 14, Velite, Tailwind, Shadcn/UI and MDX. Follow along on YouTube!
https://my-first-blog-dusky.vercel.app
120 stars 40 forks source link

Hide post and Tag when published is set to false #12

Closed Paranoia8972 closed 2 months ago

Paranoia8972 commented 2 months ago

Description:

Since the implementation of the ability to publish and unpublish posts, it is now essential to ensure that only published posts are displayed to users. This pull request addresses this requirement by adding a condition to the mapping function that renders the list of posts. This condition checks if each post is published before rendering it. If a post is unpublished, it will be excluded from the list.

Changes Made:

vercel[bot] commented 2 months ago

@Paranoia8972 is attempting to deploy a commit to the jolbol1's projects Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] commented 2 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
my-first-blog ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 29, 2024 6:37pm
jolbol1 commented 2 months ago

Thanks for this, all looks good to me!