Returns whether the given object has the specified property
the object to check
Optional
the property name to check
whether the object has the specified property
hasProp({foo: 'bar'}, 'foo'); // truehasProp({foo: 'bar'}, 'bar'); // false Copy
hasProp({foo: 'bar'}, 'foo'); // truehasProp({foo: 'bar'}, 'bar'); // false
Returns whether the given object has the specified property