flutter_swiper icon indicating copy to clipboard operation
flutter_swiper copied to clipboard

Page state cannot be maintained

Open ModWU opened this issue 4 years ago • 2 comments

Switching pages reinitializes, Page state cannot be maintained. And Use of mixin 'AutomaticKeepAliveClientMixin' is ineffective.

图片

This is a bug, this value is so big, no wonder you can't keep the state, I just change it to 6.

图片

I hope you can optimize the code here!

ModWU avatar Oct 09 '20 02:10 ModWU

hi @ModWU 请问你有办法解决 这个问题吗

jiangyh1024 avatar Apr 30 '21 04:04 jiangyh1024

https://pub.flutter-io.cn/packages/carousel_view 如果你要开启循环切换的功能请使用我的插件来保持页面状态,不过你需要修改一下flutter框架中的类,为Element类添加一个方法,在我插件报错的地方有注释说明,你找到即可,当然需要保持状态的页面你也需要with AutomaticKeepAliveClientMixin@jiangyh1024

ModWU avatar May 05 '21 09:05 ModWU