list tile with flutter switch flutter code example
Example: SwitchListTile flutter
Flutter SwitchListTile Widget
-------------------------------
SwitchListTile(
title: const Text('Lights'),
value: ans,
onChanged: (bool value) {
setState(() {
ans = value;
});
},
secondary: const Icon(Icons.lightbulb_outline),
),