Search code examples
androidiosfluttercross-platformtoast

'Fluttertoast' is deprecated and shouldn't be used. Will be removed in further release


I was using Flutter Toast https://pub.dev/packages/fluttertoast in my project and it was working fine a week ago, today i've opened my project and updates the flutter and dart and now it is showing mw that Flutter Toast is deprecated and try replacing the use of the deprecated member with the replacement.dart(deprecated_member_use). i don't know what to do? is there any recommended library to show toasts in flutter which is using on scalable applications or how do i fix this issue?


Solution

  • From the package's API docs, you just have to replace Fluttertoast with FlutterToast (note the change with the capital T) and the showToast method parameters too have been changed.

    Refer to the How To Use for more details and snippet