Closed Retr0sec7 closed 2 years ago
The dialog is shown using the function showDialog
. Hence it is not a widget and cannot be used as a widget.
@Retr0sec7 a little late maybe but, you could use BlocListener to react to state changes on your cubit or bloc, then show the dialog. Hope that helps.
Hello, I'm currently building an app with bloc/cubit state management. I want to show the dialogs based on a current state, but I can't call them outside a button function. So is there any way to return it as a Widget ?
Error: The element type Set<AwesomeDialog> can't be assigned to the list type 'Widget'
So for example: