* A specialized version of `_.map` for arrays without support for iteratee * shorthands. * * @private * @param {Array} [array] The array to iterate over. * @param {Function} iteratee The function invoked per iteration. * @returns {Array} Returns the new mapp
(array, iteratee)
| 11256 | * @returns {Array} Returns the new mapped array. |
| 11257 | */ |
| 11258 | function arrayMap(array, iteratee) { |
| 11259 | var index = -1, |
| 11260 | length = array == null ? 0 : array.length, |
| 11261 | result = Array(length); |
| 11262 | |
| 11263 | while (++index < length) { |
| 11264 | result[index] = iteratee(array[index], index, array); |
| 11265 | } |
| 11266 | return result; |
| 11267 | } |
| 11268 | |
| 11269 | /** |
| 11270 | * Appends the elements of `values` to `array`. |
no test coverage detected