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.
|
is_string = function(input) {
|
|
if (Object.prototype.toString.call(input) === '[object String]')
|
|
return true;
|
|
else
|
|
return false;
|
|
};
|
|
console.log(is_string('w3resource'));
|
|
console.log(is_string([1, 2, 4, 0]));
|