eitherx 2.0.1 copy "eitherx: ^2.0.1" to clipboard
eitherx: ^2.0.1 copied to clipboard

Either provides a way to handle errors and exceptions in a more expressive and concise way

example/lib/main.dart

import 'package:eitherx/eitherx.dart';

void main() {
  final myEither = right<String, int>(45);

  final String result = myEither.fold(
    (error) => 'Error: $error',
    (value) => 'Value: $value',
  );

  print(result); // Output: Value: 45
}
2
likes
160
pub points
72%
popularity

Publisher

unverified uploader

Either provides a way to handle errors and exceptions in a more expressive and concise way

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

More

Packages that depend on eitherx