html5 - get image blob after using sanitizer angular2 -


i'm using angular2 dom sanitizer read image file. want upload file firebase storage. however, unable find way convert sanitized image blob or can uploaded.

readimage2(inputvalue: any): observable<any> {     var file:file = inputvalue.files[0];     return this.ng2imgmaxservice.compress([file], this.maximagesize).mergemap( (result) => {       const compressedimage = window.url.createobjecturl(result);       const compressedimagetrusted=this.sanitizer.bypasssecuritytrusturl(compressedimage);       return observable.create((observer) => {           observer.next({imageurl: compressedimagetrusted});       })   }) } 

in code, want upload compressedimagetrusted file firebase storage. file has type safeurlimplwhich i'm not sure how convert can upload firebase storage. appreciated.


Comments

Popular posts from this blog

What is happening when Matlab is starting a "parallel pool"? -

php - Cannot override Laravel Spark authentication with own implementation -

Qt QGraphicsScene is not accessable from QGraphicsView (on Qt 5.6.1) -