Open
Description
I'm doing some tests and I'm calling swipperController.previous inside the onIndexChanged method of the swipper. Both next() and previous() have no effect whatsoever. Here is the code Im using:
_listPerguntas.isNotEmpty
? Swiper(
itemCount: _listPerguntas.length,
controller: _swiperController,
loop: false,
layout: SwiperLayout.TINDER,
itemWidth: MediaQuery.of(context).size.width * 0.8,
itemHeight: MediaQuery.of(context).size.width * 0.5,
itemBuilder: (BuildContext context, int index) {
return _listPerguntas[index];
},
onIndexChanged: (index) {
print('index changed');
_swiperController.previous();
},
)
: Container(),
is the implementation wrong or is this a legit issue?
Metadata
Metadata
Assignees
Labels
No labels