diff --git a/src/pages/Contributors/GetContributor.tsx b/src/pages/Contributors/GetContributor.tsx index 890d1652..a76c8ab2 100644 --- a/src/pages/Contributors/GetContributor.tsx +++ b/src/pages/Contributors/GetContributor.tsx @@ -1,10 +1,17 @@ import { SettingsContext } from '@/lib/context/settings'; import Image from 'next/image'; -import { useContext, useEffect, useState } from 'react'; +import Link from 'next/link'; +import { useEffect, useState, useContext } from 'react'; +interface Contributor { + login: string; + avatar_url: string; + contributions: number; + html_url: string; +} function GetContributor() { - const [contributors, setContributors] = useState([]); + const [contributors, setContributors] = useState([]); const { theme } = useContext(SettingsContext); @@ -15,7 +22,7 @@ function GetContributor() { const data = await res.json(); const contributorsData = data.filter( - (contributor: any) => !contributor.login.includes('dependabot[bot]') + (contributor: Contributor) => !contributor.login.includes('dependabot[bot]') ); setContributors(contributorsData); }; @@ -39,7 +46,7 @@ function GetContributor() { className="w-[100%] flex flex-wrap justify-evenly pt-10" style={{ rowGap: '2.5rem' }} > - {contributors?.map((contributor: any, i) => ( + {contributors?.map((contributor: Contributor, i) => (

{contributor.login}

{contributor.contributions} Commits

- - - +
))}