V
V
Vasily Khryagin2020-12-17 12:44:14
Slick
Vasily Khryagin, 2020-12-17 12:44:14

Slick removes id in slides and adds its own, how to leave previous ids?

This bug is in the slick only with the addition of dots. As I understand it, in order to move through the slides using your ID. How to leave both your ID and add a slick ID id="slick-slide40"?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anton Litvinenko, 2020-12-17
@podkudahka

If you look at the markup offered by the documentation

<div class="your-class">
  <div>your content</div>
  <div>your content</div>
  <div>your content</div>
</div>

Then the slider uses these empty divs for its own purposes and works with them.
Just leave them blank. And let your slides be nested in them, with the classes you need, IDs, etc.
<div class="your-class">
  <div>
    <div class="my-slide">
      my content
    </div>
  </div>
  <div>
    <div class="my-slide">
      my content
    </div>
  </div>
  <div>
    <div class="my-slide">
      my content
    </div>
  </div>
</div>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question