Answers for "javascript check if string contains any numbers"

13

javascript check if string is number

if (typeof myVar === 'string'){
    //I am indeed a string
}
Posted by: Guest on July-23-2019
1

check if a string contains digits js

function hasNumber(myString) {
  return /\d/.test(myString);
}
Posted by: Guest on July-22-2020

Code answers related to "javascript check if string contains any numbers"

Code answers related to "Javascript"

Browse Popular Code Answers by Language