简体   繁体   English

如何使用ionic 2在幻灯片中显示多个对象?

[英]How to display the multiple objects in slide using ionic 2?

I am new to ionic 2, I want to display the multiple products in single slide,I am able to display the slide but i am getting small dots below the image.How can i remove the dots. 我是离子2的新手,我想在一张幻灯片中显示多个产品,我可以显示幻灯片,但是在图像下方出现小点。如何去除这些点。 Below is my html code: 以下是我的html代码:

<ion-row class="brandNameSlideSize">
<ion-slides pager [options]="mySlideOptionsCategory">
   <ion-slide *ngFor="let catName of brandName" 
   (click)="infoBrandItem(catName);">
       <img class="imageCat" src={{catName.image}}>
       <p>{{catName.name}}</p>
      </ion-slide>    
   </ion-slides>
  </ion-row>

Below is my ts file code: 以下是我的ts文件代码:

mySlideOptionsCategory = {
slidesPerView: 4
 };
this.productServices.getBrandName(function(data){
 _this.logger.debug("checking procutName" +data);
 _this.brandName = data.data.categories;
 })

Set the pager="false" in your ion-slides tag. 在您的ion-slides标签中设置pager="false" This should solve it. 这应该解决。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM