Answers for "what is the best way to get a number from string javascript"

3

js get number from string

thenum = "foo3bar5".match(/\d+/)[0] // "3"
Posted by: Guest on January-08-2021

Code answers related to "what is the best way to get a number from string javascript"

Code answers related to "Javascript"

Browse Popular Code Answers by Language