mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-09 18:37:50 +00:00
Remove references to _.
This commit is contained in:
11
has.js
11
has.js
@@ -6,7 +6,6 @@ import hasPath from './_hasPath.js';
|
||||
*
|
||||
* @static
|
||||
* @since 0.1.0
|
||||
* @memberOf _
|
||||
* @category Object
|
||||
* @param {Object} object The object to query.
|
||||
* @param {Array|string} path The path to check.
|
||||
@@ -14,18 +13,18 @@ import hasPath from './_hasPath.js';
|
||||
* @example
|
||||
*
|
||||
* var object = { 'a': { 'b': 2 } };
|
||||
* var other = _.create({ 'a': _.create({ 'b': 2 }) });
|
||||
* var other = create({ 'a': create({ 'b': 2 }) });
|
||||
*
|
||||
* _.has(object, 'a');
|
||||
* has(object, 'a');
|
||||
* // => true
|
||||
*
|
||||
* _.has(object, 'a.b');
|
||||
* has(object, 'a.b');
|
||||
* // => true
|
||||
*
|
||||
* _.has(object, ['a', 'b']);
|
||||
* has(object, ['a', 'b']);
|
||||
* // => true
|
||||
*
|
||||
* _.has(other, 'a');
|
||||
* has(other, 'a');
|
||||
* // => false
|
||||
*/
|
||||
function has(object, path) {
|
||||
|
||||
Reference in New Issue
Block a user