SecurityError:对于base64 Angular 2,操作不安全

时间:2017-12-14 14:15:00

标签: angular security sanitize

我在使用SecurityError: The operation is insecure.显示图片时收到错误Base64。我已经应用Sanitize,如下所示,我也收到错误。

constructor(private _sanitizer: DomSanitizer) { }
    transform(v: string) {
        return this._sanitizer.bypassSecurityTrustResourceUrl(v);
    }

0 个答案:

没有答案