feat: added author info in article page
This commit is contained in:
parent
b842d124a9
commit
1e7f0f9e4a
3 changed files with 33 additions and 0 deletions
|
@ -6,6 +6,7 @@ import {getImage} from "astro:assets";
|
|||
import {siteConfig} from "../../config";
|
||||
import ReplyViaEmail from "../../components/ReplyViaEmail.astro";
|
||||
import { ExtractFirstImage } from '../../plugins/extract-images';
|
||||
import AuthorInfo from "../../components/helper/authors/Info.astro";
|
||||
|
||||
export async function getStaticPaths() {
|
||||
const blogEntries = await getCollection('posts');
|
||||
|
@ -45,6 +46,7 @@ const cover = customFeaturedImage || matchedImage_src?.src || firstImageURL || `
|
|||
author={authorInfo.name}
|
||||
>
|
||||
<h1 class="title">{entry.data.title}</h1>
|
||||
<AuthorInfo id={authorId} />
|
||||
<span class="date">{new Date(entry.data.pubDate).toISOString().split('T')[0]}</span>
|
||||
<div class="content">
|
||||
<Content />
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue