Aquarius.component.define('Widget/SwiperChristmas', function ($element, options) { var defaults = { slidesPerView: 5, spaceBetween: 30, breakpoints: {} }; function SwiperChristmas() { } SwiperChristmas.prototype = { init: function () { var self = this; this.$element = $element; this.options = Aquarius.extend(defaults, options); this.arrowLeft = '.swiper-button-prev'; this.arrowRight = '.swiper-button-next'; this.pagination = '.swiper-pagination'; this.initSwiper(); this.events(); }, events: function () { const self = this; }, initSwiper: function () { console.log(this.options.breakpoints) this.swiper = new Swiper(this.$element.find('.swiper'), { slidesPerView: this.options.slidesPerView, spaceBetween: this.options.spaceBetween, pagination: { el: this.pagination, clickable: true, }, breakpoints: this.options.breakpoints, navigation: { nextEl: this.arrowRight, prevEl: this.arrowLeft, }, on: { init: () => { } } }); console.log(this.swiper) } }; return SwiperChristmas; });