Added the Porter Stemmer module to improve searches. This doesn't deal with some...
[yaffs-website] / node_modules / uncss / node_modules / lodash / wrapperFlatMap.js
1 /**
2  * This method is the wrapper version of `_.flatMap`.
3  *
4  * @name flatMap
5  * @memberOf _
6  * @category Seq
7  * @param {Function|Object|string} [iteratee=_.identity] The function invoked per iteration.
8  * @returns {Object} Returns the new `lodash` wrapper instance.
9  * @example
10  *
11  * function duplicate(n) {
12  *   return [n, n];
13  * }
14  *
15  * _([1, 2]).flatMap(duplicate).value();
16  * // => [1, 1, 2, 2]
17  */
18 function wrapperFlatMap(iteratee) {
19   return this.map(iteratee).flatten();
20 }
21
22 module.exports = wrapperFlatMap;