I'm trying to match empty strings, non-digit characters or numbers with more than 1 digit.
Examples:
"", "a", "abc", "10"
I tried:
/^([^1-9]*)|(\d{2,})$/
but it doesn't work.
I'm trying to match empty strings, non-digit characters or numbers with more than 1 digit.
Examples:
"", "a", "abc", "10"
I tried:
/^([^1-9]*)|(\d{2,})$/
but it doesn't work.
You can use following regex for that:
/^(\d{2,}|[^\d]+|)$/
/^[^\d]*|\d{2,}$/ didn't work for you but /^([^\d]*|\d{2,})$/ did.