toNumEither<L> function

Either<L, num> Function(String) toNumEither<L>(
  1. L onLeft()
)

Convert this String to num, returns the result of onLeft for invalid inputs.

Implementation

Either<L, num> Function(String) toNumEither<L>(L Function() onLeft) =>
    (str) => str.toNumEither(onLeft);