Answer the question
In order to leave comments, you need to log in
Why is the image from the web not displayed in Angular2?
Assigned a link to the image to the variable.
imageUrl = 'https://angular.io/resources/images/logos/angular2/angular.png';
<img [src]="imageUrl"
<img src="{{ imageUrl }}"
<img src="https://angular.io/resources/images/logos/angular2/angular.png"
Answer the question
In order to leave comments, you need to log in
A banal question, are you creating a variable in the same component? Are you creating via this (this.imageUrl) ?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question