D
D
DeniSidorenko2019-01-25 10:29:50
Owl Carousel
DeniSidorenko, 2019-01-25 10:29:50

Why doesn't owl see the items in the function?

Hello, I have this code

var storiesItems = $('.stories-items');

  storiesItems.owlCarousel({
    items: 1,
    dots: false,
    nav: true,
    onInitialize: callback
  })

  function callback(event){
    var items  = event;
    console.log(items)
  }

The output in the console is 0. Despite the fact that the slider works from here and it has 4 elements

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question