lodash._createwrapper
Advanced tools
Comparing version 4.0.2 to 4.0.3
105
index.js
/** | ||
* lodash 4.0.2 (Custom Build) <https://lodash.com/> | ||
* lodash 4.0.3 (Custom Build) <https://lodash.com/> | ||
* Build: `lodash modularize exports="npm" -o ./` | ||
* Copyright 2012-2016 The Dojo Foundation <http://dojofoundation.org/> | ||
* Copyright jQuery Foundation and other contributors <https://jquery.org/> | ||
* Released under MIT license <https://lodash.com/license> | ||
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> | ||
* Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors | ||
* Available under MIT license <https://lodash.com/license> | ||
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors | ||
*/ | ||
@@ -35,3 +35,4 @@ | ||
var funcTag = '[object Function]', | ||
genTag = '[object GeneratorFunction]'; | ||
genTag = '[object GeneratorFunction]', | ||
symbolTag = '[object Symbol]'; | ||
@@ -310,3 +311,4 @@ /** Used to match leading and trailing whitespace. */ | ||
* @param {Function} func The function to wrap. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` for more details. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` | ||
* for more details. | ||
* @param {*} [thisArg] The `this` binding of `func`. | ||
@@ -364,3 +366,4 @@ * @returns {Function} Returns the new wrapped function. | ||
* @param {Function} func The function to wrap. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` for more details. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` | ||
* for more details. | ||
* @param {number} arity The arity of `func`. | ||
@@ -403,7 +406,10 @@ * @returns {Function} Returns the new wrapped function. | ||
* @param {Function|string} func The function or method name to wrap. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` for more details. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` | ||
* for more details. | ||
* @param {*} [thisArg] The `this` binding of `func`. | ||
* @param {Array} [partials] The arguments to prepend to those provided to the new function. | ||
* @param {Array} [partials] The arguments to prepend to those provided to | ||
* the new function. | ||
* @param {Array} [holders] The `partials` placeholder indexes. | ||
* @param {Array} [partialsRight] The arguments to append to those provided to the new function. | ||
* @param {Array} [partialsRight] The arguments to append to those provided | ||
* to the new function. | ||
* @param {Array} [holdersRight] The `partialsRight` placeholder indexes. | ||
@@ -476,5 +482,7 @@ * @param {Array} [argPos] The argument positions of the new function. | ||
* @param {Function} func The function to wrap. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` for more details. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` | ||
* for more details. | ||
* @param {*} thisArg The `this` binding of `func`. | ||
* @param {Array} partials The arguments to prepend to those provided to the new function. | ||
* @param {Array} partials The arguments to prepend to those provided to | ||
* the new function. | ||
* @returns {Function} Returns the new wrapped function. | ||
@@ -510,7 +518,9 @@ */ | ||
* @param {Function} func The function to wrap. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` for more details. | ||
* @param {number} bitmask The bitmask of wrapper flags. See `createWrapper` | ||
* for more details. | ||
* @param {Function} wrapFunc The function to create the `func` wrapper. | ||
* @param {*} placeholder The placeholder value. | ||
* @param {*} [thisArg] The `this` binding of `func`. | ||
* @param {Array} [partials] The arguments to prepend to those provided to the new function. | ||
* @param {Array} [partials] The arguments to prepend to those provided to | ||
* the new function. | ||
* @param {Array} [holders] The `partials` placeholder indexes. | ||
@@ -656,5 +666,7 @@ * @param {Array} [argPos] The argument positions of the new function. | ||
* @memberOf _ | ||
* @since 0.1.0 | ||
* @category Lang | ||
* @param {*} value The value to check. | ||
* @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. | ||
* @returns {boolean} Returns `true` if `value` is correctly classified, | ||
* else `false`. | ||
* @example | ||
@@ -682,2 +694,3 @@ * | ||
* @memberOf _ | ||
* @since 0.1.0 | ||
* @category Lang | ||
@@ -706,8 +719,61 @@ * @param {*} value The value to check. | ||
/** | ||
* Checks if `value` is object-like. A value is object-like if it's not `null` | ||
* and has a `typeof` result of "object". | ||
* | ||
* @static | ||
* @memberOf _ | ||
* @since 4.0.0 | ||
* @category Lang | ||
* @param {*} value The value to check. | ||
* @returns {boolean} Returns `true` if `value` is object-like, else `false`. | ||
* @example | ||
* | ||
* _.isObjectLike({}); | ||
* // => true | ||
* | ||
* _.isObjectLike([1, 2, 3]); | ||
* // => true | ||
* | ||
* _.isObjectLike(_.noop); | ||
* // => false | ||
* | ||
* _.isObjectLike(null); | ||
* // => false | ||
*/ | ||
function isObjectLike(value) { | ||
return !!value && typeof value == 'object'; | ||
} | ||
/** | ||
* Checks if `value` is classified as a `Symbol` primitive or object. | ||
* | ||
* @static | ||
* @memberOf _ | ||
* @since 4.0.0 | ||
* @category Lang | ||
* @param {*} value The value to check. | ||
* @returns {boolean} Returns `true` if `value` is correctly classified, | ||
* else `false`. | ||
* @example | ||
* | ||
* _.isSymbol(Symbol.iterator); | ||
* // => true | ||
* | ||
* _.isSymbol('abc'); | ||
* // => false | ||
*/ | ||
function isSymbol(value) { | ||
return typeof value == 'symbol' || | ||
(isObjectLike(value) && objectToString.call(value) == symbolTag); | ||
} | ||
/** | ||
* Converts `value` to an integer. | ||
* | ||
* **Note:** This function is loosely based on [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). | ||
* **Note:** This function is loosely based on | ||
* [`ToInteger`](http://www.ecma-international.org/ecma-262/6.0/#sec-tointeger). | ||
* | ||
* @static | ||
* @memberOf _ | ||
* @since 4.0.0 | ||
* @category Lang | ||
@@ -748,2 +814,3 @@ * @param {*} value The value to convert. | ||
* @memberOf _ | ||
* @since 4.0.0 | ||
* @category Lang | ||
@@ -767,2 +834,8 @@ * @param {*} value The value to process. | ||
function toNumber(value) { | ||
if (typeof value == 'number') { | ||
return value; | ||
} | ||
if (isSymbol(value)) { | ||
return NAN; | ||
} | ||
if (isObject(value)) { | ||
@@ -769,0 +842,0 @@ var other = isFunction(value.valueOf) ? value.valueOf() : value; |
{ | ||
"name": "lodash._createwrapper", | ||
"version": "4.0.2", | ||
"version": "4.0.3", | ||
"description": "The internal lodash function `createWrapper` exported as a module.", | ||
@@ -5,0 +5,0 @@ "homepage": "https://lodash.com/", |
@@ -1,2 +0,2 @@ | ||
# lodash._createwrapper v4.0.2 | ||
# lodash._createwrapper v4.0.3 | ||
@@ -18,2 +18,2 @@ The internal [lodash](https://lodash.com/) function `createWrapper` exported as a [Node.js](https://nodejs.org/) module. | ||
See the [package source](https://github.com/lodash/lodash/blob/4.0.2-npm-packages/lodash._createwrapper) for more details. | ||
See the [package source](https://github.com/lodash/lodash/blob/4.0.3-npm-packages/lodash._createwrapper) for more details. |
Sorry, the diff of this file is not supported yet
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
Mixed license
License(Experimental) Package contains multiple licenses.
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
28893
772
1