isInt method
Checks if the string represents an integer value.
Example:
print('10'.isInt()); // true
print('3.14'.isInt()); // false
Implementation
bool isInt() => int.tryParse(this) != null;
Checks if the string represents an integer value.
Example:
print('10'.isInt()); // true
print('3.14'.isInt()); // false
bool isInt() => int.tryParse(this) != null;