Skip to main content

Type Alias: LeagueOf<S>

LeagueOf<S> = S extends "baseball" ? BaseballLeague | string & object : S extends "basketball" ? BasketballLeague | string & object : S extends "curling" ? CurlingLeague | string & object : S extends "football" ? FootballLeague | string & object : S extends "hockey" ? HockeyLeague | string & object : S extends "lacrosse" ? LacrosseLeague | string & object : S extends "soccer" ? SoccerLeague | string & object : S extends "tennis" ? TennisLeague | ... & ... : S extends "volleyball" ? VolleyballLeague | ... : never

Defined in: packages/sporty/src/api.ts:110

League accepted by surface(sport, …) for sport S (a generated league name; any string compiles).

Type Parameters​

S​

S extends Sport