title: Owl Carousel returning errors with higher version of jQuery
body: <p>I'm trying to install Owl Carousel 2 in my website.I have added following files for owl-carousel.</p>
  
  <pre><code>&lt;script src="~/Scripts/jquery-3.1.1.min.js" defer&gt;&lt;/script&gt;
  &lt;script src="~/Scripts/js/owl-carousel.js"defer&gt;&lt;/script&gt;
  &lt;link rel="stylesheet" href="~/Content/css/owl.carousel.css"&gt;
  </code></pre>
  
  <p>Added following function to call Jquery</p>
  
  <pre><code>$(".owl-demo").owlCarousel({
          items: 2,
          itemsDesktop: [1199, 2],
          itemsDesktopSmall: [979, 3],
          pagination: false,
          rewindNav: false,
          slideBy: 2,
          scrollPerPage: true,
          afterAction: function () {
              if (this.itemsAmount &gt; this.visibleItems.length) {
                  $('.next').show();
                  $('.prev').show();
  
                  $('.next').removeClass('disabled');
                  $('.prev').removeClass('disabled');
                  if (this.currentItem == 0) {
                      $('.prev').addClass('disabled');
                  }
                  if (this.currentItem == this.maximumItem) {
                      $('.next').addClass('disabled');
                  }
              } else {
                  $('.next').hide();
                  $('.prev').hide();
              }
          }
      });
  
      $(".next").click(function () {
          $(".owl-demo").trigger('owl.next');
      })
      $(".prev").click(function () {
          $(".owl-demo").trigger('owl.prev');
      })
  </code></pre>
  
  <p>Added following HTML code</p>
  
  <pre><code>&lt;div class="carousel"&gt;
                              &lt;div class="owl-demo owl-carousel"&gt;
                                  &lt;div class="item"&gt;
                                      &lt;img src="~/Images/slider-img.png" /&gt;
                                      &lt;div class="img-title"&gt;text will come here&lt;/div&gt;
                                  &lt;/div&gt;
                                  &lt;div class="item"&gt;
                                      &lt;img src="~/Images/slider-img.png" /&gt;
                                      &lt;div class="img-title"&gt;text will come here&lt;/div&gt;
                                  &lt;/div&gt;
                                  &lt;div class="item"&gt;
                                      &lt;img src="~/Images/slider-img.png" /&gt;
                                      &lt;div class="img-title"&gt;text will come here&lt;/div&gt;
                                  &lt;/div&gt;
                                  &lt;div class="item"&gt;
                                      &lt;img src="~/Images/slider-img.png" /&gt;
                                      &lt;div class="img-title"&gt;text will come here&lt;/div&gt;
                                  &lt;/div&gt;
                              &lt;/div&gt;
  
                              &lt;div class="customNavigation"&gt;
                                  &lt;a id="customnavi1" class="btn prev"&gt;
                                      &lt;img src="~/lib/images/BackButtonBlack.PNG" /&gt;
                                  &lt;/a&gt;
                                  &lt;a id="customnavi2" class="btn next"&gt;
                                      &lt;img src="~/lib/images/NextArrowBlack.PNG" /&gt;
                                  &lt;/a&gt;
                              &lt;/div&gt;
                          &lt;/div&gt;
  </code></pre>
  
  <p>But still facing follwing issue 
  <a href="https://i.stack.imgur.com/d1Y9J.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/d1Y9J.png" alt="enter image description here"></a></p>
  
  <p>And I have no idea why it's returning this error.</p>