Takaro - v0.4.11
    Preparing search index...

    Function flatMapDeep

    • This method is like _.flatMap except that it recursively flattens the mapped results.

      Type Parameters

      • T

      Parameters

      • collection:
            | Dictionary<T | ListOfRecursiveArraysOrValues<T>>
            | NumericDictionary<T | ListOfRecursiveArraysOrValues<T>>
            | null
            | undefined

        The collection to iterate over.

      Returns T[]

      Returns the new flattened array.

      4.7.0

      function duplicate(n) {
      return [[[n, n]]];
      }

      _.flatMapDeep([1, 2], duplicate);
      // => [1, 1, 2, 2]
    • Type Parameters

      • T
      • TResult

      Parameters

      • collection: List<T> | null | undefined
      • iteratee: ListIterator<T, TResult | ListOfRecursiveArraysOrValues<TResult>>

      Returns TResult[]

      _.flatMapDeep

    • Type Parameters

      • T extends object
      • TResult

      Parameters

      • collection: T | null | undefined
      • iteratee: ObjectIterator<T, TResult | ListOfRecursiveArraysOrValues<TResult>>

      Returns TResult[]

      _.flatMapDeep

    • Parameters

      • collection: object | null | undefined
      • iteratee: string

      Returns any[]

      _.flatMapDeep

    • Parameters

      • collection: object | null | undefined
      • iteratee: object

      Returns boolean[]

      _.flatMapDeep