1
this.file.dataDirectory zeigte Null, Ich habe Cordova global installiert, aber immer noch bin ich nicht in der Lage, eine Lösung zu finden.Was habe ich falsch gemacht?this.file.dataDirectory zeigte null in ionic2
download() {
const fileTransfer: FileTransferObject = this.transfer.create();
const url = 'http://www.example.com/file.pdf';
fileTransfer.download(url, this.file.dataDirectory + 'file.pdf').then((entry) => {
console.log('download complete: ' + entry.toURL());
}, (error) => {
// handle error
});
}