isDecimal function

bool isDecimal(
  1. dynamic input
)

Implementation

bool isDecimal(dynamic input) =>
    input != null &&
    ((input is num && !isNaN(input)) ||
        (input is! num &&
            (parseFloat(input) != null || parseInt(input, 10) != null)));