Sha256: c5dafc73426c5056a92074ee339544f7385536c325c5770a811a4044913a24a3

Contents?: true

Size: 553 Bytes

Versions: 153

Compression:

Stored size: 553 Bytes

Contents

/**
 * A specialized version of `_.map` for arrays without support for callback
 * shorthands and `this` binding.
 *
 * @private
 * @param {Array} array The array to iterate over.
 * @param {Function} iteratee The function invoked per iteration.
 * @returns {Array} Returns the new mapped array.
 */
function arrayMap(array, iteratee) {
  var index = -1,
      length = array.length,
      result = Array(length);

  while (++index < length) {
    result[index] = iteratee(array[index], index, array);
  }
  return result;
}

module.exports = arrayMap;

Version data entries

153 entries across 80 versions & 8 rubygems

Version Path
trusty-festivity-extension-2.3.2 node_modules/bower/node_modules/configstore/node_modules/js-yaml/node_modules/argparse/node_modules/lodash/internal/arrayMap.js
trusty-festivity-extension-2.3.2 node_modules/bower/node_modules/inquirer/node_modules/lodash/internal/arrayMap.js
trusty-festivity-extension-2.3.1 node_modules/bower/node_modules/inquirer/node_modules/lodash/internal/arrayMap.js
trusty-festivity-extension-2.3.1 node_modules/bower/node_modules/configstore/node_modules/js-yaml/node_modules/argparse/node_modules/lodash/internal/arrayMap.js
trusty-festivity-extension-2.3.0 node_modules/bower/node_modules/inquirer/node_modules/lodash/internal/arrayMap.js
trusty-festivity-extension-2.3.0 node_modules/bower/node_modules/configstore/node_modules/js-yaml/node_modules/argparse/node_modules/lodash/internal/arrayMap.js
eslint_node_modules-1.6.0.1 vendor/node_modules/eslint/node_modules/inquirer/node_modules/lodash/internal/arrayMap.js
eslint_node_modules-1.6.0.1 vendor/node_modules/eslint/node_modules/js-yaml/node_modules/argparse/node_modules/lodash/internal/arrayMap.js
eslint_node_modules-1.6.0 vendor/node_modules/eslint/node_modules/inquirer/node_modules/lodash/internal/arrayMap.js
eslint_node_modules-1.6.0 vendor/node_modules/eslint/node_modules/js-yaml/node_modules/argparse/node_modules/lodash/internal/arrayMap.js
gulp_assets-1.0.0.pre.5 template/node_modules/lodash/internal/arrayMap.js
gulp_assets-1.0.0.pre.4 template/node_modules/lodash/internal/arrayMap.js
gulp_assets-1.0.0.pre.3 template/node_modules/lodash/internal/arrayMap.js