Latest
function default
import { default } from "https://dotland.deno.dev/x/lodash_es@v0.0.2/src/flatMapDepth.js";

This method is like _.flatMap except that it recursively flattens the mapped results up to depth times.

Examples

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

_.flatMapDepth([1, 2], duplicate, 2); // => [[1, 1], [2, 2]]

Parameters

collection

The collection to iterate over.

iteratee
depth