I need to capture a number passed as appended integers to a CSS class. My regex is pretty weak, what I'm looking to do is pretty simple. I thought that "negative word boundary" \B
was the flag I wanted but I guess I was wrong
string = "foo bar-15";
var theInteger = string.replace('/bar\-\B', ''); // expected result = 15