Getting unsafe URL error in console while displaying an image in Angular 6
Here i am taking the image
<br>Primary Image <input type="file" (change)="readUrl($event)">
In the other component, I want my image to be shown
<tr *ngFor="let x of response">
<td>
<img [src]="x.productPrimaryImage">
</td>
</tr>
Method to get the path of the image.
readUrl(event) {
this.productPrimaryImage = event.target.value;
}
WARNING: sanitizing unsafe URL value C:\Users\mayursinghal\Pictures\Screenshot (9).png (see http://g.co/ng/security#xss)