Files
lodash/identity.js
John-David Dalton e2aef0def9 Bump to v4.3.0.
2016-02-08 00:43:24 -08:00

21 lines
349 B
JavaScript

/**
* This method returns the first argument given to it.
*
* @static
* @memberOf _
* @category Util
* @param {*} value Any value.
* @returns {*} Returns `value`.
* @example
*
* var object = { 'user': 'fred' };
*
* _.identity(object) === object;
* // => true
*/
function identity(value) {
return value;
}
module.exports = identity;