I see in dart we can use named parameters to call a function :
https://medium.com/@codingfriday.dev/function-parameters-in-dart-1e84110a163f
I try to replicate this in flutterflow.
This usual code is working but don't accepts named parameters :
Future<void> myTest(
String message,
int durationSec,
) async {
// The code
}
myTest("hello", 2);
But this code with braces tells me "Failed to process parameters" :
Future<void> myTest({
String message,
int durationSec,}
) async {
// The code
}
myTest(message:"hello", durationSec: 2);
Why ? Is there a special way to do it with flutterflow ?
Thank you