• Count the number of distinct entries i the specified array, optionally provide a map function that returns the value making an object unique.

    Type Parameters

    • T

    Parameters

    • itr: Iterable<T>

      iterable object or array

    • Optional map: ((item) => any)

      unique key fn

        • (item): any
        • Parameters

          • item: T

          Returns any

    Returns number