How can i get the index of the previous slide?
I am using the following code:
var glide = new Glide('.glide', {})
var prevIndex = null
glide.on('run.before', () => {
prevIndex = glide.index
})
glide.mount()
Is there an easier way to get the index of the previous slide?