How do I get the count of slides in the slider?
See original GitHub issueI want to “sync” the slider based on some passed date. For example: I have slides with identifier 1
, 2
, 5
. So I add <div id="slide-id-1">...</div>
respectively for every ID.
Now, I get some other data: 1
, 2
, 4
. So I have to remove slide with ID 5
. My first thought is to iterate through every slide based on their index
and then call slick('removeSlide' index)
. However, I can’t find in the docs a method to get the count of slides.
How can I get this?
Issue Analytics
- State:
- Created 6 years ago
- Reactions:2
- Comments:5
Top Results From Across the Web
Slick.js: Get current and total slides (ie. 3/5) - Stack Overflow
The slider object contains the slide count as property. Slick < 1.5. $('.slideshow').slick({ slide: 'img', autoplay: true, dots: true, ...
Read more >Show the slide number and total number of slides on every slide
Show the slide number and total number of slides on every slide · On the View tab, in the Presentation Views group, click...
Read more >slick slider with count - CodePen
1. var $slider = $('.slider'); ; 2. ; 3. if ($slider.length) { ; 4. var currentSlide; ; 5. var slidesCount;.
Read more >How to add a slide count to a slider using Soliloquy
To add a slide counter to your Soliloquy slides, just add the following code to a new file at wp-content/plugins/soliloquy-slide-count.php . <?
Read more >Get slide count · Issue #1219 · kenwheeler/slick - GitHub
simeydotme commented on Apr 8, 2015. $(".slider").
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’m also very interested in this.
Thanks for property name slideCount. Now I can get the number of slides with this.