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.

8 lines (7 loc) 647 B
import { SpellId, SpellKey, SpellName, Spells } from '../objects/generated/Spells'; /** Get a summoner spell by its **id**, **key** or **name**. */ export declare function getSpell(id_key_name: SpellId | SpellKey | SpellName): typeof Spells[keyof typeof Spells]; export declare function isSpellId(id: number | null | undefined): id is SpellId; export declare function isSpellKey(key: string | null | undefined): key is SpellKey; export declare function isSpellName(name: string | null | undefined): name is SpellName; export declare function isSpell(id_key_name: number | string | null | undefined): id_key_name is SpellId | SpellKey | SpellName;