Function map

Curried _map

  • Type Parameters

    • T1
    • T2

    Returns
        | Curried2<(val: T1, index?: number, arr?: T1[]) => T2, T1[], T2[]>
        | Curried2<
            (val: T1, key?: string, obj?: Record<string, T1>) => T2,
            Record<string, T1>,
            Record<string, T2>,
        >

  • Type Parameters

    • T1
    • T2

    Parameters

    • fn: (val: T1, index?: number, arr?: T1[]) => T2

    Returns Curried1<T1[], T2[]>

  • Type Parameters

    • T1
    • T2

    Parameters

    • fn: (val: T1, key?: string, obj?: Record<string, T1>) => T2

    Returns Curried1<Record<string, T1>, Record<string, T2>>

  • Type Parameters

    • T1
    • T2

    Parameters

    • fn: (val: T1, index?: number, arr?: T1[]) => T2
    • arr: T1[]

    Returns T2[]

  • Type Parameters

    • T1
    • T2

    Parameters

    • fn: (val: T1, key?: string, obj?: Record<string, T1>) => T2
    • obj: Record<string, T1>

    Returns Record<string, T2>