Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR DART

flutter toast message not showing

#add f(luttertoast:<latest-version>)  dependency to your pubspec
#if its giving no platform set for toast then simple just unistall 
#app from phone and re-run 

Future<bool?>  showToastMessage(message, color)
  {
    return Fluttertoast.showToast(
        msg: message,
        toastLength: Toast.LENGTH_SHORT,
        gravity: ToastGravity.CENTER,
        timeInSecForIosWeb: 1,
        backgroundColor: color,
        textColor:  Colors.white,
        fontSize: 16.0
    );
  }
Source by pub.dev #
 
PREVIOUS NEXT
Tagged: #flutter #toast #message #showing
ADD COMMENT
Topic
Name
9+5 =