import contributors from './contributors.json' export interface Contributor { name: string avatar: string } export interface CoreTeam { avatar: string name: string github: string twitter?: string sponsors?: boolean description: string packages?: string[] functions?: string[] } const contributorsAvatars: Record = {} function getAvatarUrl(name: string) { return `https://github.com/${name}.png` } const contributorList = (contributors as string[]).reduce((acc, name) => { contributorsAvatars[name] = getAvatarUrl(name) acc.push({ name, avatar: contributorsAvatars[name] }) return acc }, [] as Contributor[]) export { contributorList as contributors }