Set/get [data-swiper-slide-index] for all swiper slides. #5072
Unanswered
sohilsshah
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Check that this is really a bug
Reproduction link
https://codesandbox.io/s/d4vlk
Bug description
When loop is set to true, I can see the [data-swiper-slide-index] attached to all the swiper slides. But it isn't available otherwise. I have a use case where I have image with unique ID inside each of the slide. When I match the id of that image, I should be able to get the index of the parent slide & use slideTo(index) to go to that slide.
Expected Behavior
No response
Actual Behavior
No response
Swiper version
7.0.8
Platform/Target and Browser Versions
Windows/ all browsers
Validations
Would you like to open a PR for this bug?
Beta Was this translation helpful? Give feedback.
All reactions