isNumber property

bool get isNumber

Checks if the string contains only numeric characters.

Implementation

bool get isNumber => regex(r'^[0-9]+$');