flutter-carousel-slider
flutter-carousel-slider copied to clipboard
Widgets are being disposed during animation when using StackTransform
As the title says, the child widgets of the carousel are being disposed. This leads to a problem if you have some async logic when initiating the state of the widget. For example in my scenario, I'm fetching image from database and this leads to flashing.
See the gif
CarouselSlider.builder(
slideTransform: StackTransform(),
itemCount: viewModel.projects.length,
slideBuilder: (index) => InspirationDetailView(
project: viewModel.projects[index],
),
),