Answers for "how do you check if something is a string javascript"

0

javascript check if var is string

if (typeof a_string === 'string') {
    // this is a string
}
Posted by: Guest on October-12-2020
1

if is a string javascript

function isString(x) {
  return Object.prototype.toString.call(x) === "[object String]"
}
Posted by: Guest on April-06-2021

Code answers related to "how do you check if something is a string javascript"

Code answers related to "Javascript"

Browse Popular Code Answers by Language