Created
January 11, 2019 22:12
-
-
Save wpexplorer/efaff7ba406bd65cbeee6561e05c24a2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
( function( $ ) { | |
'use strict'; | |
function yourCustomCarousels { | |
// Make sure scripts are loaded | |
if ( undefined === $.fn.wpexOwlCarousel || undefined === $.fn.imagesLoaded ) { | |
return; | |
} | |
$( '.your-custom-carousels', $context ).each( function() { | |
var $this = $( this ), | |
$data = $this.data(); | |
$this.imagesLoaded( function() { | |
var owl = $this.wpexOwlCarousel( { | |
animateIn : false, | |
animateOut : false, | |
lazyLoad : false, | |
dots : true, | |
nav : false | |
} ); | |
} ); | |
} ); | |
} | |
$( document ).ready(function() { | |
yourCustomCarousels(); | |
} ); | |
} ) ( jQuery ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment