chore: run prettier for tags page

This commit is contained in:
Lays 2023-09-08 15:45:27 +08:00
parent 669d821b80
commit a06efea2cb

View File

@ -34,8 +34,8 @@ export default function TagPage({ params }: { params: { tag: string } }) {
const tag = decodeURI(params.tag)
// Capitalize first letter and convert space to dash
const title = tag[0].toUpperCase() + tag.split(' ').join('-').slice(1)
const filteredPosts = allCoreContent(sortPosts(
allBlogs.filter((post) => post.tags && post.tags.map((t) => slug(t)).includes(tag))
))
const filteredPosts = allCoreContent(
sortPosts(allBlogs.filter((post) => post.tags && post.tags.map((t) => slug(t)).includes(tag)))
)
return <ListLayout posts={filteredPosts} title={title} />
}