Package selection guidance compiled from public package information, community data, and project usage.
A Flutter package that enables the creation of grouped lists with collapsible sections and sticky headers, ideal for organizing content hierarchically. It integrates seamlessly with Sliver widgets, making it suitable for use in custom scroll views like CustomScrollView. The package supports all major platforms including Android, iOS, Web, macOS, Windows, and Linux, offering a consistent experience across devices. It simplifies complex list interactions with minimal boilerplate code.
Use cases
Grouped data display
Collapsible section lists
Sticky header navigation
Custom scroll views
Dynamic content organization
Enhanced user interface for long lists
Key features
Expandable/collapsible sections
Sticky section headers
Sliver widget compatibility
Cross-platform support
Minimal setup required
Smooth animations
Suitable for
Developers building complex lists
UI designers needing interactive layouts
Apps with hierarchical data
Scrollable interfaces with headers
Mobile and web applications
Considerations
Requires understanding of Sliver widgets
May impact performance with very large datasets
Limited customization beyond basic styling
Best suited for moderate-sized grouped data
Not recommended for simple flat lists
Original README
Original README snapshot from the linked source repository. Visit the repository for the latest content.
sticky_and_expandable_list
Flutter implementation of sticky headers and expandable list.Support use it in a CustomScrollView.
Build a grouped list, which support expand/collapse section and sticky header.
Use it with CustomScrollView、SliverAppBar.
Listen the scroll offset of current sticky header, current sticky header index and switching header index.
Only use one list widget, so it supports large data and a normal memory usage.
More section customization support, you can return a new section widget by sectionBuilder, to customize background,expand/collapse animation, section layout, and so on.
In the pubspec.yaml of your flutter project, add the following dependency:
dependencies:sticky_and_expandable_list:^1.1.3
Basic Usage
sectionList is a custom data source for ExpandableListView.
We should create a model list to store the information of each section, the model must implement ExpandableListSection.