Question

I'm trying to create a carousel of items, that can be filtered.

I've been trying to use MixItUp and Slick together to accomplish this. But they aren't playing well together. MixItUp hides the items, but Slick seems to unhide them almost immediately. Is there any other library that would work better with Slick for this purpose, or even bxSlider?

$(document).ready(function(){

    $('.one-time').slick({
    dots: false,
    infinite: true,
    speed: 100,
    slidesToShow: 3,
    slidesToScroll: 1
  });

$('#product_carousel').mixItUp();

$('#product_carousel').on('mixEnd', function(e, state){

   $('.one-time').slick();
});


});
Was it helpful?

Solution

Check the latest version of Slick. I saw this and decided to add a filter method. You can use it like:

$('#yourSlider').slickFilter(':even');

and use unfilter to return to the original state:

$('#yourSlider').slickUnfilter();

It accepts jQuery filter syntax, so selectors and comparators both work.

Enjoy!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top