You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
uploadAndGetImageWithMaxSize and uploadAndGetImageWithMaxSizeAndMetas always rejected (noticeable in the stackblitz demo, even if the resultant image is smaller than the set 1MB limit)
#115
Open
nik2208 opened this issue
Sep 26, 2024
· 1 comment
Hey so one thing i did to get around this is const MAX_MEGABYTE = 2; this.imageCompress.uploadFile().then((val) => { let byteCount = this.imageCompress.byteCount(val.image) console.log('here') if(byteCount > (MAX_MEGABYTE *1024*1024)) { this.imageCompress.getImageWithMaxSizeAndMetas(val, MAX_MEGABYTE).then(val =>this.Upload(val), (rejected)=> this.Reject(rejected)) } else{ this.Upload((val)) } }, (rejected)=> this.Reject(rejected))
well... I think I've been too extensive in the title..
The text was updated successfully, but these errors were encountered: