flash static method
Implementation
static void flash(
BuildContext context,
String message, {
bool isError = false,
}) {
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(
content: Text(message),
backgroundColor: isError ? Colors.red : Colors.green,
behavior: SnackBarBehavior.floating,
duration: const Duration(seconds: 3),
),
);
}