This callback has been added to keep track of the current index.
Personally this callback is needed because I'm using animations at the foreGround component. When this animation is triggered the swiper scrolls back to the scrollToIndex's value. Via this callback you are able to track the current index, and pass it back to the component.
Closing this PR since onMomentumScrollEnd does the exact same thing (I thought it only triggered on the end of the list but it does on the end of every 'swipe')
This callback has been added to keep track of the current index.
Personally this callback is needed because I'm using animations at the
foreGround
component. When this animation is triggered the swiper scrolls back to thescrollToIndex
's value. Via this callback you are able to track the current index, and pass it back to the component.