onlyDigits property

String get onlyDigits

Keeps only digit characters.

Implementation

String get onlyDigits => replaceAll(RegExp(r'\D'), '');