Answers for "javascript check value is string"

1

check if value string js

var value = "test string"
console.log(typeof value === "string")
Posted by: Guest on October-25-2021
6

js check if variable is string

if (typeof myVar === 'integer'){
    //I am indeed an integer
}

if (typeof myVar === 'boolean'){
    //I am indeed a boolean
}
Posted by: Guest on March-19-2020
0

if variable is string javascript

if (typeof myVar === 'integer'){
    //I am indeed an integer
}

if (typeof myVar === 'boolean'){
    //I am indeed a boolean
}
Posted by: Guest on January-01-1970

Code answers related to "javascript check value is string"

Code answers related to "Javascript"

Browse Popular Code Answers by Language