Sha256: 479ae3e185f7daceee159faa1d786cbca09d07c376e11c3547f498029ea92c05

Contents?: true

Size: 674 Bytes

Versions: 291

Compression:

Stored size: 674 Bytes

Contents

/**
 * This method is like `_.tap` except that it returns the result of `interceptor`.
 * The purpose of this method is to "pass thru" values replacing intermediate
 * results in a method chain sequence.
 *
 * @static
 * @memberOf _
 * @since 3.0.0
 * @category Seq
 * @param {*} value The value to provide to `interceptor`.
 * @param {Function} interceptor The function to invoke.
 * @returns {*} Returns the result of `interceptor`.
 * @example
 *
 * _('  abc  ')
 *  .chain()
 *  .trim()
 *  .thru(function(value) {
 *    return [value];
 *  })
 *  .value();
 * // => ['abc']
 */
function thru(value, interceptor) {
  return interceptor(value);
}

module.exports = thru;

Version data entries

291 entries across 267 versions & 32 rubygems

Version Path
trusty-cms-6.3.1 node_modules/lodash/thru.js
immosquare-cleaner-0.1.51 node_modules/lodash/thru.js
boring_generators-0.15.0 tmp/templates/app_template/node_modules/lodash/thru.js
clapton-0.0.26 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.25 lib/clapton/javascripts/node_modules/lodash/thru.js
immosquare-cleaner-0.1.50 node_modules/lodash/thru.js
clapton-0.0.24 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.23 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.22 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.21 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.20 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.19 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.18 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.17 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.16 lib/clapton/javascripts/node_modules/lodash/thru.js
clapton-0.0.15 lib/clapton/javascripts/node_modules/lodash/thru.js
immosquare-cleaner-0.1.49 node_modules/lodash/thru.js
clapton-0.0.14 lib/clapton/javascripts/node_modules/lodash/thru.js
immosquare-cleaner-0.1.48 node_modules/lodash/thru.js
clapton-0.0.13 lib/clapton/javascripts/node_modules/lodash/thru.js