Quantcast
Channel: Ionic Forum - Latest posts
Viewing all articles
Browse latest Browse all 228595

Swiper in Ionic2 throws console error "params[param] is null"

$
0
0

We use Swiper 3.1.2 from http://www.idangero.us/swiper/ in Ionic 2. You can use this in your app without importing anything.

Ionic 2 Source Files:


Example Slides with images:


The conference app is using this at the very beginning (all related code is in the tutorial directory):

https://github.com/driftyco/ionic-conference-app/tree/master/www/app/tutorial

So you can pass your options to the slider in options

<ion-slides pager [options]="extraOptions" (slideChanged)="onSlideChanged($event)">

JS:

    this.extraOptions = {
      loop: 'true',
      pagination: '.swiper-pagination',
      nextButton: '.swiper-button-next',
      prevButton: '.swiper-button-prev',
      paginationClickable: true,
      spaceBetween: 30,
      centeredSlides: true,
      autoplay: 100,
      autoplayDisableOnInteraction: false
    }

Viewing all articles
Browse latest Browse all 228595

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>