UNPKG

lol-constants

Version:

League of Legends constants, functions, and types. Provides a plathera of functions to easily convert between ID, Name, and Key for champions, items, summoner spells, and runes.

17 lines (16 loc) 498 B
/** E.g. `Faker#T1` ⇒ `{name: 'Faker', tag: 'T1'}` */ export declare function splitRiotId(riotId: string, /** @default '#' */ splitChar?: string): RiotId; /** Default `splitChar` is "#". */ export declare function makeRiotId(riotId: RiotId, /** @default '#' */ splitChar?: string): string; /** Default `splitChar` is "#". */ export declare function validateRiotId(riotId: string, /** @default '#' */ splitChar?: string): boolean; export type RiotId = { name: string; tag: string; };