isEmailValid static method

bool isEmailValid(
  1. String email
)

Implementation

static bool isEmailValid(String email) {
  final RegExp regex = RegExp(
    r'^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$',
  );
  return regex.hasMatch(email);
}