get the number on a string js code example
Example 1: js get number from string
thenum = "foo3bar5".match(/\d+/)[0] // "3"
Example 2: how to find number in string javascript
var str = 10
thenum = "foo3bar5".match(/\d+/)[0] // "3"
var str = 10