I want to achieve a layout of item chips(newest,most popular) like pic1
but what i can achieved is this in picture 2
i have searched many example but i don't get it where i did wrong in using WRAP.I tried to wrap the whole listview but not working. here is my code
Container(
height: SizeConfig.screenHeight / 2,
child: ListView.builder(
shrinkWrap: true,
itemCount: _selectKeywords.length,
itemBuilder: (context, index) {
return Wrap(
children: <Widget>[
Chip(
label: Text(
_selectKeywords[index],
),
onDeleted: () {
setState(() {
_selectKeywords.removeAt(index);
});
},
),
],
);
}),
),