diff --git a/src/components/Card.astro b/src/components/Card.astro index a623797..1fb2c55 100644 --- a/src/components/Card.astro +++ b/src/components/Card.astro @@ -1,17 +1,19 @@ --- +import type { Frontmatter } from "src/pages/index.astro"; +import formatDatetime from "src/utils/formatDatetime"; + export interface Props { - title: string; - body: string; - href: string; + href?: string; + post: Frontmatter; secHeading?: boolean; } -const { href, title, body, secHeading = true } = Astro.props; +const { href, post, secHeading = true } = Astro.props; ---
- {body} + {post.description}