skip to Main Content

Flutter – Checkbox Checks All The Tasks Instead of The Relevant One Only

taskContainer(String taskName, String taskPriority, String taskDetails) { return Padding( padding: const EdgeInsets.only(bottom: 10), child: Container( height: 80, decoration: BoxDecoration( color: Colours().containerColour, borderRadius: BorderRadius.circular(10), boxShadow: [ BoxShadow( color: Colours().buttonShadow, blurRadius: 5, offset: const Offset(0, 5), ), ], ), child: Row( mainAxisAlignment:…

VIEW QUESTION

Flutter – Why does not "await" work in async method?

Why does not "await" work? Future<void> f1() async{ Future.delayed(Duration(seconds:2), (){ print('f1'); }); } void main() async{ print('start'); await f1(); print('end'); } output start end f1 but await working in next code. Future<void> f1() async{ return Future.delayed(Duration(seconds:2), (){ print('f1'); }); }…

VIEW QUESTION
Back To Top
Search