@MiriK wrote:
Hi guys,
I have a problem with saving blob to my android device via cordova-plugin-file writeFile method. There is no problem in iOS and some Android devices.
async downloadLogbook(vehicle) { try { const data = await this.logbookProvider.getLogbookPdf(vehicle.id).toPromise() const blob = new Blob([data._body], { type: 'application/pdf' }) const filename = 'logbook.pdf' const opt: IWriteOptions = { replace: true } await this.file.writeFile(this.file.dataDirectory, filename, blob, opt) } catch (err) { this.actionCtrl.showError(err) }
method writeFile is not returning anything. No err, no Success
Any idea?
Thanks
Posts: 1
Participants: 1