Skip to content

roh-it/FlutterToastAlertPlugin

Repository files navigation

FlutterToastAlert

Flutter plugin which shows a custom toast message on Android (https://github.com/GrenderG/Toasty) and custom alert message on iOS (https://github.com/vikmeup/SCLAlertView-Swift)

Github: https://github.com/roh-it/FlutterToastAlertPlugin

Steps to install

Add fluttertoastalert: ^1.0.1 under dependencies in your pubspec.yaml file

To use the plugin, add this line to where the toast or alert must be displayed

FlutterToastAlert.showToastAndAlert(type: Type.Success,iosTitle: "Wow",iosSubtitle: "It Works",androidToast: "It Works",toastDuration: 3,toastShowIcon: true);
FlutterToastAlert.showToastAndAlert(type: Type.Error,iosTitle: "Error",iosSubtitle: "Doesn't work",androidToast: "Doesn't work",toastDuration: 3,toastShowIcon: true);
FlutterToastAlert.showToastAndAlert(type: Type.Warning,iosTitle: "Warning",iosSubtitle: "Warning message",androidToast: "Warning message",toastDuration: 3,toastShowIcon: true);
FlutterToastAlert.showToastAndAlert(type: Type.Info,iosTitle: "Info",iosSubtitle: "Information",androidToast: "Information",toastDuration: 3,toastShowIcon: true);
FlutterToastAlert.showToastAndAlert(type: Type.Normal,iosTitle: "Normal",iosSubtitle: "Normal Message",androidToast: "Normal Message",toastDuration: 3,toastShowIcon: true);

image image

About

A flutter plugin that shows both custom Toast message (https://github.com/GrenderG/Toasty) on android and custom Alert message (https://github.com/vikmeup/SCLAlertView-Swift) on iOS.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published