MCPcopy Create free account
hub / github.com/TheOrcDev/github-creature / StarsCount

Function StarsCount

components/header.tsx:61–75  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

59 </header>
60 );
61}
62
63export async function StarsCount() {
64 "use cache";
65
66 const data = await fetch(
67 "https://api.github.com/repos/theorcdev/github-creature"
68 );
69 const json = await data.json();
70 const stars = json.stargazers_count;
71
72 return (
73 <span className="hidden w-12 text-muted-foreground text-xs tabular-nums sm:inline">
74 {stars >= 1000 ? `${(stars / 1000).toFixed(1)}k` : stars.toLocaleString()}
75 </span>
76 );
77}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected