Skip to content
pubscout

scrollable_positioned_list

0.3.8, released 4 years ago by google.dev

A Flutter list with helper methods to programmatically scroll to an item.

WASM-readyRepository archivedQuiet but busy
$ flutter pub add scrollable_positioned_list
Source repository

What it does

Provides a list widget that works similarly to ListView.builder but allows programmatic scrolling or jumping to specific items by index. It also helps determine which items are currently visible on the screen.

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

Use it when

  • You need to programmatically scroll or jump to a specific item index in a long list.
  • You need to track and monitor which items are currently visible in the viewport.

Skip it when

  • You only need a standard ListView without programmatic scrolling to arbitrary indices.

Strengths

  • Allows smooth scrolling or direct jumping to specific item indices.
  • Provides listeners to track visible items on screen.

Weaknesses

  • Some newer features like offset listening are currently experimental and subject to bugs.

Setup

Kind
Flutter widgets
Effort
Low
Code generation
No
Direct dependencies
1
final ItemScrollController itemScrollController = ItemScrollController();
final ItemPositionsListener itemPositionsListener = ItemPositionsListener.create();

ScrollablePositionedList.builder(
  itemCount: 500,
  itemBuilder: (context, index) => Text('Item $index'),
  itemScrollController: itemScrollController,
  itemPositionsListener: itemPositionsListener,
);

Alternatives

Packages that do the same job and could replace scrollable_positioned_list.

Works with

Packages commonly used together with scrollable_positioned_list: ones it builds on, ones built on it, and its own family.