isNumericOnly property

bool get isNumericOnly

Checks if string consist only numeric. Numeric only doesn't accepting "." which double data type have

Implementation

bool get isNumericOnly => matchesRegex(r'^\d+$');