digitsOnly property
String
get
digitsOnly
Extract only digits (handy for phone numbers)
Implementation
String get digitsOnly => replaceAll(RegExp(r'\D'), '');
Extract only digits (handy for phone numbers)
String get digitsOnly => replaceAll(RegExp(r'\D'), '');