Open thecheebo opened 3 years ago
Try this
for signin:
final Function toggleView;
const SignIn({Key? key, required this.toggleView}) : super(key: key);
for register:
final Function toggleView;
const SignUpScreen({Key? key, required this.toggleView}) : super(key: key);
The code
final Function toggleView; SignIn({this.toggleView});
andfinal Function toggleView; Register({this.toggleView});
are both returning this error:
The parameter 'toggleView' can't have a value of 'null' because of its type, but the implicit default value is 'null'. (Documentation) Try adding either an explicit non-'null' default value or the 'required' modifier.