UNPKG

soccer-go

Version:

Soccer CLI for stats and results.

71 lines (70 loc) 1.52 kB
import Table from 'cli-table3'; import { IRowable } from '../tableBuilders/BaseTableBuilder'; export default class Scorer implements IRowable { playerName: string; teamName: string; goals: number; assists: number | null; penalties: number | null; playedMatches: number; constructor(data: IScorerJson); toRow: (idx: number) => Table.Cell[]; } export interface IScorersResponseJson { count: number; filters: { season: string; limit: number; }; competition: ICompetition; season: ISeason; scorers: IScorerJson[]; } export interface IScorerJson { player: IPlayer; team: ITeam; playedMatches: number; goals: number; assists: number | null; penalties: number | null; } interface IPlayer { id: number; name: string; firstName: string; lastName: string; dateOfBirth: string; nationality: string; section: string; position: string | null; shirtNumber: number | null; lastUpdated: string; } interface ITeam { id: number; name: string; shortName: string; tla: string; crest: string; address: string; website: string; founded: number; clubColors: string; venue: string; lastUpdated: string; } interface ICompetition { id: number; name: string; code: string; type: string; emblem: string; } interface ISeason { id: number; startDate: string; endDate: string; currentMatchday: number; winner: null; } export {};