Object
Has

_.has(object, path)

Checks if path is a direct property of object.

Arguments

object (Object): The object to query.
path (Array|string): The path to check.

Returns

(boolean): Returns true if path exists, else false.

Example

Deep