Comparing version 3.9.0 to 3.9.2
@@ -7,4 +7,4 @@ import baseDifference from '../internal/baseDifference'; | ||
/** | ||
* Creates an array excluding all values of the provided arrays using | ||
* [`SameValueZero`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-samevaluezero) | ||
* Creates an array of unique `array` values not included in the other | ||
* provided arrays using [`SameValueZero`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-samevaluezero) | ||
* for equality comparisons. | ||
@@ -11,0 +11,0 @@ * |
@@ -8,4 +8,4 @@ import baseIndexOf from '../internal/baseIndexOf'; | ||
/** | ||
* Creates an array of unique values in all provided arrays using | ||
* [`SameValueZero`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-samevaluezero) | ||
* Creates an array of unique values that are included in all of the provided | ||
* arrays using [`SameValueZero`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-samevaluezero) | ||
* for equality comparisons. | ||
@@ -12,0 +12,0 @@ * |
@@ -6,4 +6,4 @@ import baseFlatten from '../internal/baseFlatten'; | ||
/** | ||
* Creates an array of unique values, in order, of the provided arrays using | ||
* [`SameValueZero`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-samevaluezero) | ||
* Creates an array of unique values, in order, from all of the provided arrays | ||
* using [`SameValueZero`](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-samevaluezero) | ||
* for equality comparisons. | ||
@@ -10,0 +10,0 @@ * |
@@ -6,3 +6,3 @@ import baseDifference from '../internal/baseDifference'; | ||
/** | ||
* Creates an array that is the [symmetric difference](https://en.wikipedia.org/wiki/Symmetric_difference) | ||
* Creates an array of unique values that is the [symmetric difference](https://en.wikipedia.org/wiki/Symmetric_difference) | ||
* of the provided arrays. | ||
@@ -9,0 +9,0 @@ * |
import baseRandom from '../internal/baseRandom'; | ||
import isIterateeCall from '../internal/isIterateeCall'; | ||
import shuffle from './shuffle'; | ||
import toArray from '../lang/toArray'; | ||
import toIterable from '../internal/toIterable'; | ||
@@ -33,4 +33,16 @@ | ||
} | ||
var result = shuffle(collection); | ||
result.length = nativeMin(n < 0 ? 0 : (+n || 0), result.length); | ||
var index = -1, | ||
result = toArray(collection), | ||
length = result.length, | ||
lastIndex = length - 1; | ||
n = nativeMin(n < 0 ? 0 : (+n || 0), length); | ||
while (++index < n) { | ||
var rand = baseRandom(index, lastIndex), | ||
value = result[rand]; | ||
result[rand] = result[index]; | ||
result[index] = value; | ||
} | ||
result.length = n; | ||
return result; | ||
@@ -37,0 +49,0 @@ } |
@@ -1,4 +0,6 @@ | ||
import baseRandom from '../internal/baseRandom'; | ||
import toIterable from '../internal/toIterable'; | ||
import sample from './sample'; | ||
/** Used as references for `-Infinity` and `Infinity`. */ | ||
var POSITIVE_INFINITY = Number.POSITIVE_INFINITY; | ||
/** | ||
@@ -19,18 +21,5 @@ * Creates an array of shuffled values, using a version of the | ||
function shuffle(collection) { | ||
collection = toIterable(collection); | ||
var index = -1, | ||
length = collection.length, | ||
result = Array(length); | ||
while (++index < length) { | ||
var rand = baseRandom(0, index); | ||
if (index != rand) { | ||
result[index] = result[rand]; | ||
} | ||
result[rand] = collection[index]; | ||
} | ||
return result; | ||
return sample(collection, POSITIVE_INFINITY); | ||
} | ||
export default shuffle; |
/** | ||
* A specialized version of `baseExtremum` for arrays whichs invokes `iteratee` | ||
* A specialized version of `baseExtremum` for arrays which invokes `iteratee` | ||
* with one argument: (value). | ||
@@ -4,0 +4,0 @@ * |
import baseIsEqualDeep from './baseIsEqualDeep'; | ||
import isObject from '../lang/isObject'; | ||
import isObjectLike from './isObjectLike'; | ||
@@ -21,3 +22,3 @@ /** | ||
} | ||
if (value == null || other == null || (!isObject(value) && !isObject(other))) { | ||
if (value == null || other == null || (!isObject(value) && !isObjectLike(other))) { | ||
return value !== value && other !== other; | ||
@@ -24,0 +25,0 @@ } |
@@ -12,4 +12,3 @@ import baseGet from './baseGet'; | ||
/** | ||
* The base implementation of `_.matchesProperty` which does not which does | ||
* not clone `value`. | ||
* The base implementation of `_.matchesProperty` which does not clone `srcValue`. | ||
* | ||
@@ -16,0 +15,0 @@ * @private |
import LazyWrapper from './LazyWrapper'; | ||
import getData from './getData'; | ||
import getFuncName from './getFuncName'; | ||
@@ -14,5 +15,13 @@ import lodash from '../chain/lodash'; | ||
var funcName = getFuncName(func); | ||
return !!funcName && func === lodash[funcName] && funcName in LazyWrapper.prototype; | ||
if (!(funcName in LazyWrapper.prototype)) { | ||
return false; | ||
} | ||
var other = lodash[funcName]; | ||
if (func === other) { | ||
return true; | ||
} | ||
var data = getData(other); | ||
return !!data && func === data[0]; | ||
} | ||
export default isLaziable; |
/** | ||
* @license | ||
* lodash 3.9.0 (Custom Build) <https://lodash.com/> | ||
* lodash 3.9.2 (Custom Build) <https://lodash.com/> | ||
* Build: `lodash modularize modern exports="es" -o ./` | ||
@@ -45,3 +45,3 @@ * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/> | ||
/** Used as the semantic version number. */ | ||
var VERSION = '3.9.0'; | ||
var VERSION = '3.9.2'; | ||
@@ -48,0 +48,0 @@ /** Used to compose bitmasks for wrapper metadata. */ |
import createExtremum from '../internal/createExtremum'; | ||
import gt from '../lang/gt'; | ||
/** Used as references for `-Infinity` and `Infinity`. */ | ||
var NEGATIVE_INFINITY = Number.NEGATIVE_INFINITY; | ||
/** | ||
@@ -51,4 +54,4 @@ * Gets the maximum value of `collection`. If `collection` is empty or falsey | ||
*/ | ||
var max = createExtremum(gt, -Infinity); | ||
var max = createExtremum(gt, NEGATIVE_INFINITY); | ||
export default max; |
import createExtremum from '../internal/createExtremum'; | ||
import lt from '../lang/lt'; | ||
/** Used as references for `-Infinity` and `Infinity`. */ | ||
var POSITIVE_INFINITY = Number.POSITIVE_INFINITY; | ||
/** | ||
@@ -51,4 +54,4 @@ * Gets the minimum value of `collection`. If `collection` is empty or falsey | ||
*/ | ||
var min = createExtremum(lt, Infinity); | ||
var min = createExtremum(lt, POSITIVE_INFINITY); | ||
export default min; |
@@ -38,3 +38,3 @@ import isIndex from '../internal/isIndex'; | ||
length = path.length, | ||
endIndex = length - 1, | ||
lastIndex = length - 1, | ||
nested = object; | ||
@@ -45,3 +45,3 @@ | ||
if (isObject(nested)) { | ||
if (index == endIndex) { | ||
if (index == lastIndex) { | ||
nested[key] = value; | ||
@@ -48,0 +48,0 @@ } else if (nested[key] == null) { |
{ | ||
"name": "lodash-es", | ||
"version": "3.9.0", | ||
"version": "3.9.2", | ||
"description": "The modern build of lodash exported as ES modules.", | ||
@@ -5,0 +5,0 @@ "homepage": "https://lodash.com/custom-builds", |
@@ -1,2 +0,2 @@ | ||
# lodash-es v3.9.0 | ||
# lodash-es v3.9.2 | ||
@@ -10,2 +10,2 @@ 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. | ||
See the [package source](https://github.com/lodash/lodash/tree/3.9.0-es) for more details. | ||
See the [package source](https://github.com/lodash/lodash/tree/3.9.2-es) for more details. |
@@ -5,3 +5,3 @@ import baseClone from '../internal/baseClone'; | ||
/** | ||
* Creates a function which performs a deep comparison between a given object | ||
* Creates a function that performs a deep comparison between a given object | ||
* and `source`, returning `true` if the given object has equivalent property | ||
@@ -8,0 +8,0 @@ * values, else `false`. |
@@ -5,3 +5,3 @@ import baseClone from '../internal/baseClone'; | ||
/** | ||
* Creates a function which compares the property value of `path` on a given | ||
* Creates a function that compares the property value of `path` on a given | ||
* object to `value`. | ||
@@ -8,0 +8,0 @@ * |
@@ -5,3 +5,4 @@ import invokePath from '../internal/invokePath'; | ||
/** | ||
* Creates a function which invokes the method at `path` on a given object. | ||
* Creates a function that invokes the method at `path` on a given object. | ||
* Any additional arguments are provided to the invoked method. | ||
* | ||
@@ -12,2 +13,3 @@ * @static | ||
* @param {Array|string} path The path of the method to invoke. | ||
* @param {...*} [args] The arguments to invoke the method with. | ||
* @returns {Function} Returns the new function. | ||
@@ -14,0 +16,0 @@ * @example |
@@ -5,4 +5,5 @@ import invokePath from '../internal/invokePath'; | ||
/** | ||
* The opposite of `_.method`; this method creates a function which invokes | ||
* the method at a given path on `object`. | ||
* The opposite of `_.method`; this method creates a function that invokes | ||
* the method at a given path on `object`. Any additional arguments are | ||
* provided to the invoked method. | ||
* | ||
@@ -13,2 +14,3 @@ * @static | ||
* @param {Object} object The object to query. | ||
* @param {...*} [args] The arguments to invoke the method with. | ||
* @returns {Function} Returns the new function. | ||
@@ -15,0 +17,0 @@ * @example |
/** | ||
* A no-operation function which returns `undefined` regardless of the | ||
* A no-operation function that returns `undefined` regardless of the | ||
* arguments it receives. | ||
@@ -4,0 +4,0 @@ * |
@@ -6,3 +6,3 @@ import baseProperty from '../internal/baseProperty'; | ||
/** | ||
* Creates a function which returns the property value at `path` on a | ||
* Creates a function that returns the property value at `path` on a | ||
* given object. | ||
@@ -9,0 +9,0 @@ * |
@@ -5,3 +5,3 @@ import baseGet from '../internal/baseGet'; | ||
/** | ||
* The opposite of `_.property`; this method creates a function which returns | ||
* The opposite of `_.property`; this method creates a function that returns | ||
* the property value at a given path on `object`. | ||
@@ -8,0 +8,0 @@ * |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
438101
13410