float static method

String? Function(String?) float({
  1. double? min,
  2. double? max,
  3. String errorMessage = 'Please enter a valid number',
})

Ensures the string is a finite floating-point number.

Implementation

static String? Function(String?) float({
  double? min,
  double? max,
  String errorMessage = 'Please enter a valid number',
}) {
  return _build(errorMessage, (v) => v.isFloat(min: min, max: max));
}