Z
Z
Zombie426792018-05-18 16:43:41
JavaScript
Zombie42679, 2018-05-18 16:43:41

addEventListener not working in IE?

Because of this piece of code in IE, all scripts crash, what's the problem?

The code scrolls through the slides in owl.carousel with the mouse wheel.

shpOwl[0].addEventListener('mousewheel', e => {
    if (e.deltaY > 0) {
      $('.shp-slider').trigger('prev.owl', [300]);
    } else {
      $('.shp-slider').trigger('next.owl', [300]);
    }
    e.preventDefault();
  }, false);

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