Answers for "how to disable switch in flutter"

1

how to disable switch in flutter

// To disable your Switch, edit its onChanged method to null like this

Switch(
  onChanged: null,
  value: true,
  inactiveThumbColor: Colors.tealAccent,
  inactiveTrackColor: Colors.tealAccent.withOpacity(0.5),
  // ...
),
Posted by: Guest on January-26-2022

Code answers related to "how to disable switch in flutter"

Code answers related to "Dart"

Browse Popular Code Answers by Language