Error: RenderBox was not laid out, Failed assertion: line 1940 pos 12: ‘hasSize’
This happens when ListView has no constrained height which makes it gets an infinite height, you can solve this using two solutions add shrinkWrap: true as a parameter which will tell the ListView to use a little space as possible, Wrap your ListView with a constrained height widget, such as a SizedBox or a Container, … Read more