Answers for "how to show dialog screen initialize flutter"

0

how to display a dialog after build in flutter

class XxxxxWidget extends StatelessWidget {

@override
Widget build(BuildContext context) {
// [NG]We want to show dialog on Container widget.

 Future.delayed(Duration.zero, () => showMyDialog(context)); // import 'dart:async';
 return Container(
  child: FlatButton(.... //same as question
Posted by: Guest on November-11-2021

Code answers related to "Dart"

Browse Popular Code Answers by Language