isIntString function
Validates that the String can be parsed as an int
(e.g. '123', '-42')
Implementation
IValidator isIntString() =>
isType<String>() &
validator(
(value) => int.tryParse(value.trim()) != null,
(value) => Expectation(
message: 'a valid formatted int String', value: value, code: 'value.format_invalid', data: {'format': 'int'}),
);