Find out which items in a ListView are visible

Issue

How can I find out which items are currently visible or invisible in a ListView?
For example, I have 100 items in ListView and when i scroll to top of screen or list, I want to detect which items appear or disappear from the viewport.

Illustration:

enter image description here

Solution

You can also use inview_notifier_list. It’s basically a normal ListView which defines a visible region and it’s children get notified when they are in that region.

enter image description here

Answered By – Ashkan Sarlak

Answer Checked By – Dawn Plyler (FlutterFixes Volunteer)

Leave a Reply

Your email address will not be published. Required fields are marked *