-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a04979f
commit 3e977d4
Showing
3 changed files
with
39 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
import PageLayout from "./PageLayout.astro"; | ||
const { | ||
data: { | ||
name, | ||
headlines, | ||
about, | ||
skills, | ||
college, | ||
profileImgLink, | ||
links, | ||
articleCount, | ||
}, | ||
} = Astro.props; | ||
--- | ||
|
||
<PageLayout title={name}> | ||
<div class="w-full max-w-[800px] py-4 mx-auto"> | ||
<p class="">Hi Author</p> | ||
</div> | ||
</PageLayout> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--- | ||
import { getCollection } from "astro:content"; | ||
import AuthorLayout from "@/layouts/AuthorLayout.astro"; | ||
export async function getStaticPaths() { | ||
const posts = await getCollection("authors"); | ||
return posts.map((post) => ({ | ||
params: { slug: post.id }, | ||
props: post, | ||
})); | ||
} | ||
const props = Astro.props; | ||
const { slug } = Astro.params; | ||
--- | ||
|
||
<AuthorLayout {...props} {slug} /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters