Reputation: 43
I need to check if string contains numbers, ".
" or "_
" or "-
".
But jslint is showing below error:
Lint at line 63160 character 53: Unescaped '-'
Below is my code.
if ( value.match( /^[0-9._-]+$/ )) {
return true;
}
Upvotes: 1
Views: 375