Answers for "The argument type 'Future<dynamic>' can't be assigned to the parameter type 'void Function()'"

3

The argument type 'Future<dynamic>' can't be assigned to the parameter type 'void Function()'

REPLACE THIS:
onPressed: Navigator.push(...)

WITH THIS:
onPressed: () => Navigator.push(...)
Posted by: Guest on October-28-2020

Code answers related to "The argument type 'Future<dynamic>' can't be assigned to the parameter type 'void Function()'"

Browse Popular Code Answers by Language