Image on Ionic2 app html page

In Ionic2 application:

Display of image(s) is successful this way:

    <ion-item>
      <ion-avatar item-start>
        <img src="{{imgPath}}">
      </ion-avatar>
    </ion-item>

but it is blank squares if I put it in ion-img:

    <ion-img src="{{imgPath}}"></ion-img>

Advice would be helpful

Hello,

try with property binding like [src]=“imgPath” instead string interpolation.

Best regards, anna-liebt

Hello,
also provide dimension of image, maybe by css etc.

Best regards, anna-liebt

1 Like

RTFM: Note: ion-img is only meant to be used inside of virtual-scroll.