Sha256: 3b3c99679e09b1320b35a0992aa12092cf028b2d4939c4a198002b71da38945f

Contents?: true

Size: 730 Bytes

Versions: 273

Compression:

Stored size: 730 Bytes

Contents

var createFind = require('./_createFind'),
    findLastIndex = require('./findLastIndex');

/**
 * This method is like `_.find` except that it iterates over elements of
 * `collection` from right to left.
 *
 * @static
 * @memberOf _
 * @since 2.0.0
 * @category Collection
 * @param {Array|Object} collection The collection to inspect.
 * @param {Function} [predicate=_.identity] The function invoked per iteration.
 * @param {number} [fromIndex=collection.length-1] The index to search from.
 * @returns {*} Returns the matched element, else `undefined`.
 * @example
 *
 * _.findLast([1, 2, 3, 4], function(n) {
 *   return n % 2 == 1;
 * });
 * // => 3
 */
var findLast = createFind(findLastIndex);

module.exports = findLast;

Version data entries

273 entries across 271 versions & 29 rubygems

Version Path
clapton-0.0.19 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.18 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.17 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.16 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.15 lib/clapton/javascripts/node_modules/lodash/findLast.js
immosquare-cleaner-0.1.49 node_modules/lodash/findLast.js
clapton-0.0.14 lib/clapton/javascripts/node_modules/lodash/findLast.js
immosquare-cleaner-0.1.48 node_modules/lodash/findLast.js
clapton-0.0.13 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.12 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.11 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.10 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.9 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.8 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.7 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.6 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.5 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.4 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.3 lib/clapton/javascripts/node_modules/lodash/findLast.js
clapton-0.0.2 lib/clapton/javascripts/node_modules/lodash/findLast.js