The new slider ion-slide in 1.2


#1

I know how to use the ion-slide-box, but I want to use the new slider ion-slide.

I works but I have no clue how to bind events to it. Like on an on-slide-change.

Any help?


#2

Don’t worry about answering this. I found the solution here:

You set the binding functions in the options. Here is a snippet from that post.

$scope.swiperOptions = { /* Whatever options */ effect: 'slide', initialSlide: 0, /* Initialize a scope variable with the swiper */ onInit: function(swiper){ $scope.swiper = swiper; }, onSlideChangeEnd: function(swiper){ console.log('The active index is ' + swiper.activeIndex); } };