chore: tipadoa konpontzen du
This commit is contained in:
1 parent
a866661a82
commit
3b47191d78
6 files changed
+65
-58
No files matched your search
+33
-23
@@ -1,28 +1,38 @@
|
||||
---
|
||||
const { slug, title, tags, description, date } = Astro.props;
|
||||
import type { CollectionEntry } from "astro:content";
|
||||
|
||||
interface Props {
|
||||
post: CollectionEntry<"posts">;
|
||||
}
|
||||
|
||||
const {
|
||||
post: {
|
||||
data: { slug, title, tags, description, added: date },
|
||||
},
|
||||
}: Props = Astro.props;
|
||||
---
|
||||
|
||||
<li class="post">
|
||||
<a href={`/post/${slug}/`} class="title">{title}</a>
|
||||
<time datetime={date}>
|
||||
{
|
||||
new Date(date).toLocaleDateString("eu", {
|
||||
year: "numeric",
|
||||
month: "short",
|
||||
day: "numeric",
|
||||
})
|
||||
}
|
||||
</time>
|
||||
<br />
|
||||
{description && <span class="excerpt">{description}</span>}
|
||||
<div>
|
||||
{
|
||||
tags &&
|
||||
tags.map((tag: string) => (
|
||||
<a class="tag" href={`/tag/${tag}`}>
|
||||
#{tag}
|
||||
</a>
|
||||
))
|
||||
}
|
||||
</div>
|
||||
<a href={`/post/${slug}/`} class="title">{title}</a>
|
||||
<time datetime={date as string}>
|
||||
{
|
||||
new Date(date).toLocaleDateString("eu", {
|
||||
year: "numeric",
|
||||
month: "short",
|
||||
day: "numeric",
|
||||
})
|
||||
}
|
||||
</time>
|
||||
<br />
|
||||
{description && <span class="excerpt">{description}</span>}
|
||||
<div>
|
||||
{
|
||||
tags &&
|
||||
tags.map((tag: string) => (
|
||||
<a class="tag" href={`/tag/${tag}`}>
|
||||
#{tag}
|
||||
</a>
|
||||
))
|
||||
}
|
||||
</div>
|
||||
</li>
|
||||
Reference in new issue
Block a user