You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
function is_object(value)
|
|
{
|
|
var datatype = typeof value;
|
|
return datatype === 'function' || datatype === 'object' && !!value;
|
|
}
|
|
|
|
console.log(is_object({name: 'Robert'}));
|
|
|
|
console.log(is_object('bar'));
|
|
|
|
console.log(is_object(72));
|