Answers for "regex validation dart"

1

dart regex

RegExp exp = new RegExp(r"(w+)");
String str = "Parse my string";
Iterable<RegExpMatch> matches = exp.allMatches(str);
Posted by: Guest on April-03-2020
0

flutter regex validation

You could make the first part optional matching either a + or 0 followed by a 9. Then match 10 digits:

^(?:[+0]9)?[0-9]{10}$
^ Start of string
(?:[+0]9)? Optionally match a + or 0 followed by 9
[0-9]{10} Match 10 digits
$ End of string
Regex demo
Posted by: Guest on March-25-2021

Code answers related to "Dart"

Browse Popular Code Answers by Language