-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(docs): add contributors page (#70)
- Loading branch information
Showing
5 changed files
with
61 additions
and
2 deletions.
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,38 @@ | ||
async function getContributors() { | ||
"use cache"; | ||
|
||
try { | ||
const res = await fetch( | ||
"https://api.github.com/repos/lazarv/react-server/contributors" | ||
); | ||
const data = await res.json(); | ||
return data.filter((contributor) => contributor.login !== "lazarv"); | ||
} catch { | ||
return []; | ||
} | ||
} | ||
|
||
export default async function Contributors() { | ||
const contributors = await getContributors(); | ||
|
||
return ( | ||
<div className="w-full my-8 flex flex-wrap gap-8 justify-center items-center"> | ||
{contributors.map((contributor) => ( | ||
<a | ||
key={contributor.login} | ||
href={`https://github.com/${contributor.login}`} | ||
target="_blank" | ||
rel="noopener noreferrer" | ||
className="flex flex-col items-center gap-2" | ||
> | ||
<img | ||
src={contributor.avatar_url} | ||
alt={contributor.login} | ||
className="w-24 h-24 rounded-full outline outline-4 outline-indigo-500 dark:outline-yellow-600" | ||
/> | ||
<div className="text-sm font-semibold">{contributor.login}</div> | ||
</a> | ||
))} | ||
</div> | ||
); | ||
} |
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
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
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
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 @@ | ||
--- | ||
title: Contributors | ||
category: Team | ||
order: 1 | ||
slug: team/contributors | ||
--- | ||
|
||
import Contributors from "../../../../components/Contributors"; | ||
|
||
<div className="container text-center max-w-xl mx-auto [&>h1]:text-4xl [&>p]:text-lg [&>p]:text-gray-700 dark:[&>p]:text-gray-400"> | ||
# Contributors | ||
|
||
A big shoutout to all the amazing contributors who’ve rolled up their sleeves, shared their skills, and helped level up this project! Your input has truly made an impact—thank you! | ||
|
||
</div> | ||
|
||
<Contributors /> |