FlutterStates/Screen becomes empty/when fixing => Code
CodePudding user response:
Try changing final Function currentCheckBoxState;
to final Function(bool?) currentCheckBoxState;
and in your void Function make your bool nullable with a ? and make a null check inside the setState with ! behind currentCheckBoxState void checkBoxCallBack(bool? currentCheckBoxState) { setState(() {isChecked = currentCheckBoxState!; }); }