📱 Flutter
Beginner
What is the GridView widget?
Answer
GridView displays a 2D scrollable grid of widgets. GridView.count creates a grid with a fixed number of columns, while GridView.extent creates one where each tile has a maximum width. For dynamic data, GridView.builder() lazily builds grid items on demand, making it memory-efficient for large datasets. The crossAxisCount and childAspectRatio properties control the grid layout.