Answers for "unsafe src img ionic"

1

ionic allow unsafe image

import {DomSanitizer} from '@angular/platform-browser';
 
@Component({
  templateUrl: 'somePage.html'
})
export class SomePage {
 
  constructor(
    public _DomSanitizer: DomSanitizer,
    ...
  ) {
  }
  
 // <img [src]="_DomSanitizer.bypassSecurityTrustUrl(imgSrcProperty)"/>
Posted by: Guest on April-12-2021

Browse Popular Code Answers by Language