lukehaas / Scrollify

A jQuery plugin that assists scrolling and snaps to sections.
MIT License
1.8k stars 580 forks source link

currentIndex not returning right value #376

Open kyds3k opened 5 years ago

kyds3k commented 5 years ago

In my code, I have the following:

before: function () { currentSlide = $.scrollify.currentIndex(); console.log('current slide is ' + currentSlide) }, after: function() { currentSlide = $.scrollify.currentIndex(); console.log('moved to slide ' + currentSlide); }

However, it's telling me that the current slide is 1 every time, instead of 0 on the first one. Any ideas?