Skip to content

Commit

Permalink
manually add slugs
Browse files Browse the repository at this point in the history
  • Loading branch information
AndrewDTR committed Oct 9, 2024
1 parent b90124a commit 6129aed
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/layouts/Blog.astro
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import BaseLayout from "./BaseLayout.astro";
const { frontmatter } = Astro.props;
const hasTags = frontmatter.tags && frontmatter.tags.length > 0;
const imgLink = `${Astro.site.origin}/og/${Astro.props.post.slug}.png`;
const imgLink = `${Astro.site.origin}/og/${frontmatter.slug}.png`;
---

<BaseLayout imgLink={imgLink}>
Expand Down
1 change: 1 addition & 0 deletions src/pages/about.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ title: "Hello World"
subtitle: "Things I've learned from saying Hello to the world"
author: Andrew
tags: ["one", "two", "three"]
slug: "hello-world"
---

![Example image](/og/index.png)
Expand Down

0 comments on commit 6129aed

Please sign in to comment.