Skip to content
pubscout

group_grid_view

1.0.1, released 4 years ago by an unverified publisher

A GridView widget that groups list items and supports headers and footers per section.

WASM-ready
$ flutter pub add group_grid_view
Source repository

What it does

Provides a GridView implementation allowing developers to group items into sections with custom headers and footers, mimicking iOS UICollectionView sections. It exposes standard GridView builder capabilities.

AI-written summary of version 1.0.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to display grid items organized in distinct sections with headers or footers.
  • You want a grid layout similar to iOS UICollectionView sections in Flutter.

Skip it when

  • You need standard linear lists instead of grids (consider a grouped list view instead).
  • You require complex staggered grid patterns not natively supported by standard grid delegates.

Strengths

  • Supports section headers and footers for grouped grid items.
  • Compatible with standard GridView builders and delegates.
  • Cross-platform support including Android, iOS, Web, Windows, macOS, and Linux.

Weaknesses

  • Limited documentation beyond basic README examples.
  • No advanced community-driven features or frequent updates mentioned in changelog.

Setup

Kind
Flutter widgets
Effort
Low
Code generation
No
Direct dependencies
0
GroupGridView(
  padding: const EdgeInsets.symmetric(horizontal: 16),
  gridDelegate: const SliverGridDelegateWithFixedCrossAxisCount(
    crossAxisCount: 3, mainAxisSpacing: 16, crossAxisSpacing: 16),
  sectionCount: dataSource.length,
  headerForSection: (section) => Container(
    padding: const EdgeInsets.symmetric(vertical: 12),
    child: Text(dataSource[section].sectionName,
      style: const TextStyle(fontSize: 22, fontWeight: FontWeight.bold))),
  itemInSectionBuilder: (_, indexPath) {
    final data = dataSource[indexPath.section].listItems[indexPath.index];
    return Container(alignment: Alignment.center, child: Text(data));
  },
  itemInSectionCount: (section) => dataSource[section].listItems.length,
)

Alternatives

Packages that do the same job and could replace group_grid_view.