showErrorAlert function
Implementation
void showErrorAlert(String errorMessage) {
log(errorMessage, logLevel: CONSOLE_LOG);
showDialog(
context: currentContext!,
builder: (BuildContext context) {
return Alerts(
title: 'ERROR',
actions: [
Text(errorMessage, style: const TextStyle(fontSize: 18)),
TextButton(
onPressed: () => Navigator.of(context).pop(),
child: const Text('OK'))
],
);
},
);
}