Skip to content

Commit

Permalink
feat: add date to Seo for blog and projects
Browse files Browse the repository at this point in the history
  • Loading branch information
theodorusclarence committed Dec 27, 2021
1 parent 688f851 commit 7f3e9d5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/pages/blog/[slug].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,9 @@ export default function SingleBlogPage({
description={frontmatter.description}
isBlog
banner={`https://res.cloudinary.com/theodorusclarence/image/upload/f_auto,c_fill,ar_4:5,w_1200/theodorusclarence/banner/${frontmatter.banner}`}
date={new Date(
frontmatter.lastUpdated ?? frontmatter.publishedAt
).toISOString()}
/>

<main>
Expand Down
1 change: 1 addition & 0 deletions src/pages/projects/[slug].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ export default function SingleProjectPage({ code, frontmatter }: ProjectType) {
<Seo
templateTitle={frontmatter.title}
description={frontmatter.description}
date={new Date(frontmatter.publishedAt).toISOString()}
/>

<main>
Expand Down

1 comment on commit 7f3e9d5

@vercel
Copy link

@vercel vercel bot commented on 7f3e9d5 Dec 27, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.