Sha256: ee23c96ff637259512dfcd11eca50f081abf43d505aa7c18f4b933074da048a7

Contents?: true

Size: 780 Bytes

Versions: 273

Compression:

Stored size: 780 Bytes

Contents

var apply = require('./_apply'),
    arrayMap = require('./_arrayMap'),
    baseIteratee = require('./_baseIteratee'),
    baseRest = require('./_baseRest'),
    baseUnary = require('./_baseUnary'),
    flatRest = require('./_flatRest');

/**
 * Creates a function like `_.over`.
 *
 * @private
 * @param {Function} arrayFunc The function to iterate over iteratees.
 * @returns {Function} Returns the new over function.
 */
function createOver(arrayFunc) {
  return flatRest(function(iteratees) {
    iteratees = arrayMap(iteratees, baseUnary(baseIteratee));
    return baseRest(function(args) {
      var thisArg = this;
      return arrayFunc(iteratees, function(iteratee) {
        return apply(iteratee, thisArg, args);
      });
    });
  });
}

module.exports = createOver;

Version data entries

273 entries across 271 versions & 29 rubygems

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