Reputation: 1243
I have SliverAppBar in my app with expandedHeight: 200,
. Below it i have ListView that display content dynamically and can have different length. If ListView has 7 or more item its works perfecly, but if its below 7 items SliverAppBar still scrolls and has a lot of black space(screenshot). How can i disable SliverAppBar scroll property? I tried to use physics: NeverScrollableScrollPhysics(),
in ListView itself, it didn't help.
Upvotes: 2
Views: 3413
Reputation: 17746
Assuming you have a the SliverAppBar
in a CustomScrollView
or similar, you'll need to set the physics
to NeverScrollableScrollPhysics()
there as well.
Upvotes: 3