Compare commits

..

1 Commits

Author SHA1 Message Date
John-David Dalton
1d77dfa4b7 Bump to v3.10.1. 2015-08-03 08:35:01 -07:00
40 changed files with 53 additions and 52 deletions

View File

@@ -1,4 +1,4 @@
# lodash-es v3.10.0
# lodash-es v3.10.1
The [modern build](https://github.com/lodash/lodash/wiki/Build-Differences) of [lodash](https://lodash.com/) exported as [ES](https://people.mozilla.org/~jorendorff/es6-draft.html) modules.
@@ -7,4 +7,4 @@ Generated using [lodash-cli](https://www.npmjs.com/package/lodash-cli):
$ lodash modularize modern exports=es -o ./
```
See the [package source](https://github.com/lodash/lodash/tree/3.10.0-es) for more details.
See the [package source](https://github.com/lodash/lodash/tree/3.10.1-es) for more details.

View File

@@ -3,7 +3,7 @@ import isIterateeCall from '../internal/isIterateeCall';
/**
* Flattens a nested array. If `isDeep` is `true` the array is recursively
* flattened, otherwise it is only flattened a single level.
* flattened, otherwise it's only flattened a single level.
*
* @static
* @memberOf _

View File

@@ -7,7 +7,7 @@ var nativeMax = Math.max;
/**
* Gets the index at which the first occurrence of `value` is found in `array`
* using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* for equality comparisons. If `fromIndex` is negative, it is used as the offset
* for equality comparisons. If `fromIndex` is negative, it's used as the offset
* from the end of `array`. If `array` is sorted providing `true` for `fromIndex`
* performs a faster binary search.
*

View File

@@ -3,7 +3,7 @@ import createSortedIndex from '../internal/createSortedIndex';
/**
* Uses a binary search to determine the lowest index at which `value` should
* be inserted into `array` in order to maintain its sort order. If an iteratee
* function is provided it is invoked for `value` and each element of `array`
* function is provided it's invoked for `value` and each element of `array`
* to compute their sort ranking. The iteratee is bound to `thisArg` and
* invoked with one argument; (value).
*

View File

@@ -8,7 +8,7 @@ import sortedUniq from '../internal/sortedUniq';
* [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* for equality comparisons, in which only the first occurence of each element
* is kept. Providing `true` for `isSorted` performs a faster search algorithm
* for sorted arrays. If an iteratee function is provided it is invoked for
* for sorted arrays. If an iteratee function is provided it's invoked for
* each element in the array to generate the criterion by which uniqueness
* is computed. The `iteratee` is bound to `thisArg` and invoked with three
* arguments: (value, index, array).

View File

@@ -26,7 +26,7 @@ function wrapperReverse() {
var value = this.__wrapped__;
var interceptor = function(value) {
return (wrapped && wrapped.__dir__ < 0) ? value : value.reverse();
return value.reverse();
};
if (value instanceof LazyWrapper) {
var wrapped = value;

View File

@@ -10,9 +10,9 @@ import values from '../object/values';
var nativeMax = Math.max;
/**
* Checks if `value` is in `collection` using
* Checks if `target` is in `collection` using
* [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* for equality comparisons. If `fromIndex` is negative, it is used as the offset
* for equality comparisons. If `fromIndex` is negative, it's used as the offset
* from the end of `collection`.
*
* @static

View File

@@ -7,7 +7,7 @@ import restParam from '../function/restParam';
/**
* Invokes the method at `path` of each element in `collection`, returning
* an array of the results of each invoked method. Any additional arguments
* are provided to each invoked method. If `methodName` is a function it is
* are provided to each invoked method. If `methodName` is a function it's
* invoked for, and `this` bound to, each element in `collection`.
*
* @static

View File

@@ -8,7 +8,7 @@ var nativeIsFinite = root.isFinite;
/**
* The opposite of `_.before`; this method creates a function that invokes
* `func` once it is called `n` or more times.
* `func` once it's called `n` or more times.
*
* @static
* @memberOf _

View File

@@ -3,7 +3,7 @@ var FUNC_ERROR_TEXT = 'Expected a function';
/**
* Creates a function that invokes `func`, with the `this` binding and arguments
* of the created function, while it is called less than `n` times. Subsequent
* of the created function, while it's called less than `n` times. Subsequent
* calls to the created function return the result of the last `func` invocation.
*
* @static

View File

@@ -32,7 +32,7 @@ var nativeMax = Math.max;
* @param {boolean} [options.leading=false] Specify invoking on the leading
* edge of the timeout.
* @param {number} [options.maxWait] The maximum time `func` is allowed to be
* delayed before it is invoked.
* delayed before it's invoked.
* @param {boolean} [options.trailing=true] Specify invoking on the trailing
* edge of the timeout.
* @returns {Function} Returns the new debounced function.

View File

@@ -3,7 +3,7 @@ import restParam from './restParam';
/**
* Defers invoking the `func` until the current call stack has cleared. Any
* additional arguments are provided to `func` when it is invoked.
* additional arguments are provided to `func` when it's invoked.
*
* @static
* @memberOf _

View File

@@ -3,7 +3,7 @@ import restParam from './restParam';
/**
* Invokes `func` after `wait` milliseconds. Any additional arguments are
* provided to `func` when it is invoked.
* provided to `func` when it's invoked.
*
* @static
* @memberOf _

View File

@@ -8,7 +8,7 @@ var nativeMax = Math.max;
* Creates a function that invokes `func` with the `this` binding of the
* created function and arguments from `start` and beyond provided as an array.
*
* **Note:** This method is based on the [rest parameter](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/rest_parameters).
* **Note:** This method is based on the [rest parameter](https://developer.mozilla.org/Web/JavaScript/Reference/Functions/rest_parameters).
*
* @static
* @memberOf _

View File

@@ -5,7 +5,7 @@ var FUNC_ERROR_TEXT = 'Expected a function';
* Creates a function that invokes `func` with the `this` binding of the created
* function and an array of arguments much like [`Function#apply`](https://es5.github.io/#x15.3.4.3).
*
* **Note:** This method is based on the [spread operator](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Spread_operator).
* **Note:** This method is based on the [spread operator](https://developer.mozilla.org/Web/JavaScript/Reference/Operators/Spread_operator).
*
* @static
* @memberOf _

View File

@@ -12,7 +12,7 @@ var LARGE_ARRAY_SIZE = 200;
* @private
* @param {Array} array The array to inspect.
* @param {Function} [iteratee] The function invoked per iteration.
* @returns {Array} Returns the new duplicate-value-free array.
* @returns {Array} Returns the new duplicate free array.
*/
function baseUniq(array, iteratee) {
var index = -1,

View File

@@ -8,7 +8,7 @@ import realNames from './realNames';
* @returns {string} Returns the function name.
*/
function getFuncName(func) {
var result = func.name,
var result = (func.name + ''),
array = realNames[result],
length = array ? array.length : 0;

View File

@@ -11,11 +11,12 @@ import lodash from '../chain/lodash';
* @returns {boolean} Returns `true` if `func` has a lazy counterpart, else `false`.
*/
function isLaziable(func) {
var funcName = getFuncName(func);
if (!(funcName in LazyWrapper.prototype)) {
var funcName = getFuncName(func),
other = lodash[funcName];
if (typeof other != 'function' || !(funcName in LazyWrapper.prototype)) {
return false;
}
var other = lodash[funcName];
if (func === other) {
return true;
}

View File

@@ -37,7 +37,7 @@ function lazyValue() {
takeCount = nativeMin(length, this.__takeCount__);
if (!isArr || arrLength < LARGE_ARRAY_SIZE || (arrLength == length && takeCount == length)) {
return baseWrapperValue((isRight && isArr) ? array.reverse() : array, this.__actions__);
return baseWrapperValue(array, this.__actions__);
}
var result = [];

View File

@@ -5,7 +5,7 @@
* @private
* @param {Array} array The array to inspect.
* @param {Function} [iteratee] The function invoked per iteration.
* @returns {Array} Returns the new duplicate-value-free array.
* @returns {Array} Returns the new duplicate free array.
*/
function sortedUniq(array, iteratee) {
var seen,

View File

@@ -4,10 +4,10 @@ import isIterateeCall from '../internal/isIterateeCall';
/**
* Creates a clone of `value`. If `isDeep` is `true` nested objects are cloned,
* otherwise they are assigned by reference. If `customizer` is provided it is
* otherwise they are assigned by reference. If `customizer` is provided it's
* invoked to produce the cloned values. If `customizer` returns `undefined`
* cloning is handled by the method instead. The `customizer` is bound to
* `thisArg` and invoked with two argument; (value [, index|key, object]).
* `thisArg` and invoked with up to three argument; (value [, index|key, object]).
*
* **Note:** This method is loosely based on the
* [structured clone algorithm](http://www.w3.org/TR/html5/infrastructure.html#internal-structured-cloning-algorithm).
@@ -63,7 +63,7 @@ function clone(value, isDeep, customizer, thisArg) {
isDeep = false;
}
return typeof customizer == 'function'
? baseClone(value, isDeep, bindCallback(customizer, thisArg, 1))
? baseClone(value, isDeep, bindCallback(customizer, thisArg, 3))
: baseClone(value, isDeep);
}

View File

@@ -2,10 +2,10 @@ import baseClone from '../internal/baseClone';
import bindCallback from '../internal/bindCallback';
/**
* Creates a deep clone of `value`. If `customizer` is provided it is invoked
* Creates a deep clone of `value`. If `customizer` is provided it's invoked
* to produce the cloned values. If `customizer` returns `undefined` cloning
* is handled by the method instead. The `customizer` is bound to `thisArg`
* and invoked with two argument; (value [, index|key, object]).
* and invoked with up to three argument; (value [, index|key, object]).
*
* **Note:** This method is loosely based on the
* [structured clone algorithm](http://www.w3.org/TR/html5/infrastructure.html#internal-structured-cloning-algorithm).
@@ -48,7 +48,7 @@ import bindCallback from '../internal/bindCallback';
*/
function cloneDeep(value, customizer, thisArg) {
return typeof customizer == 'function'
? baseClone(value, true, bindCallback(customizer, thisArg, 1))
? baseClone(value, true, bindCallback(customizer, thisArg, 3))
: baseClone(value, true);
}

View File

@@ -7,7 +7,7 @@ import isString from './isString';
import keys from '../object/keys';
/**
* Checks if `value` is empty. A value is considered empty unless it is an
* Checks if `value` is empty. A value is considered empty unless it's an
* `arguments` object, array, string, or jQuery-like collection with a length
* greater than `0` or an object with own enumerable properties.
*

View File

@@ -3,10 +3,10 @@ import bindCallback from '../internal/bindCallback';
/**
* Performs a deep comparison between two values to determine if they are
* equivalent. If `customizer` is provided it is invoked to compare values.
* equivalent. If `customizer` is provided it's invoked to compare values.
* If `customizer` returns `undefined` comparisons are handled by the method
* instead. The `customizer` is bound to `thisArg` and invoked with three
* arguments: (value, other [, index|key]).
* instead. The `customizer` is bound to `thisArg` and invoked with up to
* three arguments: (value, other [, index|key]).
*
* **Note:** This method supports comparing arrays, booleans, `Date` objects,
* numbers, `Object` objects, regexes, and strings. Objects are compared by

View File

@@ -31,7 +31,7 @@ var objToString = objectProto.toString;
function isFunction(value) {
// The use of `Object#toString` avoids issues with the `typeof` operator
// in older versions of Chrome and Safari which return 'function' for regexes
// and Safari 8 equivalents which return 'object' for typed array constructors.
// and Safari 8 which returns 'object' for typed array constructors.
return isObject(value) && objToString.call(value) == funcTag;
}

View File

@@ -5,7 +5,7 @@ import getMatchData from '../internal/getMatchData';
/**
* Performs a deep comparison between `object` and `source` to determine if
* `object` contains equivalent property values. If `customizer` is provided
* it is invoked to compare values. If `customizer` returns `undefined`
* it's invoked to compare values. If `customizer` returns `undefined`
* comparisons are handled by the method instead. The `customizer` is bound
* to `thisArg` and invoked with three arguments: (value, other, index|key).
*

View File

@@ -1,6 +1,6 @@
/**
* @license
* lodash 3.10.0 (Custom Build) <https://lodash.com/>
* lodash 3.10.1 (Custom Build) <https://lodash.com/>
* Build: `lodash modularize modern exports="es" -o ./`
* Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
@@ -43,7 +43,7 @@ import support from './support';
import thru from './chain/thru';
/** Used as the semantic version number. */
var VERSION = '3.10.0';
var VERSION = '3.10.1';
/** Used to compose bitmasks for wrapper metadata. */
var BIND_KEY_FLAG = 2;
@@ -519,7 +519,7 @@ arrayEach(['join', 'pop', 'push', 'replace', 'shift', 'sort', 'splice', 'split',
baseForOwn(LazyWrapper.prototype, function(func, methodName) {
var lodashFunc = lodash[methodName];
if (lodashFunc) {
var key = lodashFunc.name,
var key = (lodashFunc.name + ''),
names = realNames[key] || (realNames[key] = []);
names.push({ 'name': methodName, 'func': lodashFunc });

View File

@@ -6,7 +6,7 @@ var NEGATIVE_INFINITY = Number.NEGATIVE_INFINITY;
/**
* Gets the maximum value of `collection`. If `collection` is empty or falsey
* `-Infinity` is returned. If an iteratee function is provided it is invoked
* `-Infinity` is returned. If an iteratee function is provided it's invoked
* for each value in `collection` to generate the criterion by which the value
* is ranked. The `iteratee` is bound to `thisArg` and invoked with three
* arguments: (value, index, collection).

View File

@@ -6,7 +6,7 @@ var POSITIVE_INFINITY = Number.POSITIVE_INFINITY;
/**
* Gets the minimum value of `collection`. If `collection` is empty or falsey
* `Infinity` is returned. If an iteratee function is provided it is invoked
* `Infinity` is returned. If an iteratee function is provided it's invoked
* for each value in `collection` to generate the criterion by which the value
* is ranked. The `iteratee` is bound to `thisArg` and invoked with three
* arguments: (value, index, collection).

View File

@@ -4,7 +4,7 @@ var nativeMax = Math.max,
/**
* Checks if `n` is between `start` and up to but not including, `end`. If
* `end` is not specified it is set to `start` with `start` then set to `0`.
* `end` is not specified it's set to `start` with `start` then set to `0`.
*
* @static
* @memberOf _

View File

@@ -5,7 +5,7 @@ import createAssigner from '../internal/createAssigner';
/**
* Assigns own enumerable properties of source object(s) to the destination
* object. Subsequent sources overwrite property assignments of previous sources.
* If `customizer` is provided it is invoked to produce the assigned values.
* If `customizer` is provided it's invoked to produce the assigned values.
* The `customizer` is bound to `thisArg` and invoked with five arguments:
* (objectValue, sourceValue, key, object, source).
*

View File

@@ -26,7 +26,7 @@ import toPath from '../internal/toPath';
* // => 'default'
*/
function get(object, path, defaultValue) {
var result = object == null ? undefined : baseGet(object, toPath(path), path + '');
var result = object == null ? undefined : baseGet(object, toPath(path), (path + ''));
return result === undefined ? defaultValue : result;
}

View File

@@ -5,7 +5,7 @@ import createAssigner from '../internal/createAssigner';
* Recursively merges own enumerable properties of the source object(s), that
* don't resolve to `undefined` into the destination object. Subsequent sources
* overwrite property assignments of previous sources. If `customizer` is
* provided it is invoked to produce the merged values of the destination and
* provided it's invoked to produce the merged values of the destination and
* source properties. If `customizer` returns `undefined` merging is handled
* by the method instead. The `customizer` is bound to `thisArg` and invoked
* with five arguments: (objectValue, sourceValue, key, object, source).

View File

@@ -7,7 +7,7 @@ import restParam from '../function/restParam';
/**
* Creates an object composed of the picked `object` properties. Property
* names may be specified as individual arguments or as arrays of property
* names. If `predicate` is provided it is invoked for each property of `object`
* names. If `predicate` is provided it's invoked for each property of `object`
* picking the properties `predicate` returns truthy for. The predicate is
* bound to `thisArg` and invoked with three arguments: (value, key, object).
*

View File

@@ -7,7 +7,7 @@ import toPath from '../internal/toPath';
/**
* This method is like `_.get` except that if the resolved value is a function
* it is invoked with the `this` binding of its parent object and its result
* it's invoked with the `this` binding of its parent object and its result
* is returned.
*
* @static

View File

@@ -5,7 +5,7 @@ import toPath from '../internal/toPath';
/**
* Sets the property value of `path` on `object`. If a portion of `path`
* does not exist it is created.
* does not exist it's created.
*
* @static
* @memberOf _

View File

@@ -1,6 +1,6 @@
{
"name": "lodash-es",
"version": "3.10.0",
"version": "3.10.1",
"description": "The modern build of lodash exported as ES modules.",
"homepage": "https://lodash.com/custom-builds",
"license": "MIT",

View File

@@ -3,7 +3,7 @@ import restParam from '../function/restParam';
/**
* Attempts to invoke `func`, returning either the result or the caught error
* object. Any additional arguments are provided to `func` when it is invoked.
* object. Any additional arguments are provided to `func` when it's invoked.
*
* @static
* @memberOf _

View File

@@ -23,7 +23,7 @@ import toPath from '../internal/toPath';
*/
function propertyOf(object) {
return function(path) {
return baseGet(object, toPath(path), path + '');
return baseGet(object, toPath(path), (path + ''));
};
}

View File

@@ -6,7 +6,7 @@ var nativeCeil = Math.ceil,
/**
* Creates an array of numbers (positive and/or negative) progressing from
* `start` up to, but not including, `end`. If `end` is not specified it is
* `start` up to, but not including, `end`. If `end` is not specified it's
* set to `start` with `start` then set to `0`. If `end` is less than `start`
* a zero-length range is created unless a negative `step` is specified.
*