How to display a block with an index that corresponds to the index of the active slide?
The task is to show the block, the index of which corresponds to the index of the central active slide.
There is a slider on the page, it displays 3 active slides. There is a function that adds the class
to the central slide Below the slider is a block containing blocks with content.
You need to find out the index of the central slide and assign the class
to the block with the same index When trying to find out the index of the center slide, it always returns -1.
Please help me figure it out.
Here's an example: https://codepen.io/OculusDaemon/pen/vVWmOR
< br /> P.S Using owl-carousel with
loop: falsejQuery Blake Kane, Feb 25, 2020
To place the code, please use CodePen or similar tool. Thanks you!