Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

80
Views
SlickSlider - same index

I have a slider, I would like my function to return the same slider and navigation index to me when clicked. Currently it returns the index of the slider and the navigation shows 0 all the time. I would be grateful for any help.

var slider = $('.slider-for').slick({
            slidesToShow: 1,
            slidesToScroll: 1,
            arrows: true,
            fade: true,**strong text**
            appendArrows: $('.arrow-container'),
            prevArrow: '.prev-arrow',
            nextArrow: '.next-arrow',
          });

var navigation = $('.slider-nav').slick({
                slidesToShow: 10,
                slidesToScroll: 10,
                infinite: true,
                asNavFor: '.slider-for',
                dots: false,
                centerMode: false,
                focusOnSelect: true,
                arrows: false,
              });

$(".slick-arrow").click(function(){

var currentSlider = slider.slick('slickCurrentSlide');
console.log (currentSlider)


$(".slider-nav").slick("slickNext");
var currentNavigation = navigation.slick('slickCurrentSlide');

console.log (currentNavigation)
})
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!