I am facing a problem in flutter for converting JSON data as List<Map<String, dynamic>>.
rawJson =
'[{"value":"1","label":"red"}, {"value":"2","label":"Green"}, {"value":"3","label":"Yellow"}]';
This data need to convert as List<Map<String, dynamic>>
The following code is working, but need help top things.
List<Map<String, dynamic>> _items = [
{
'value': '1',
'label': 'Red',
},
{
'value': '2',
'label': 'Green',
},
{
'value': '3',
'label': 'Yellow',
},
];