import { INumberMap, IMap } from "./interfaces"; import { isFunction } from "@vlr/object-tools"; export function get(map: IMap, key: string): T; export function get(map: INumberMap, key: number): T; export function get(map: IMap | INumberMap, key: string | number): T { if (isFunction(map.hasOwnProperty) && !map.hasOwnProperty(key)) { return undefined; } return map[key]; }