I\'m trying to construct a simple login page for my Flutter app. I\'ve successfully built the TextFields and log in/Sign in buttons. I want to add a horizontal ListView.
Expanded Widget increases it’s size as much as it can with the space available Since ListView essentially has an infinite height it will cause an error.
Column(
children: [
Flexible(
child: ListView(...),
)
],
)
Here we should use Flexible widget as it will only take the space it required as Expanded take full screen even if there are not enough widgets to render on full screen.