title: How to download a file in iOS (Ionic 2/3)?
body: <p>I am trying to download a file and save that file in iOS. I am using <a href="https://ionicframework.com/docs/native/file/" rel="noreferrer">ionic-native-file</a> plugin to achieve this. The file has been download but i could not find that file in the device.</p>
  
  <pre><code>filewrite = (): void =&gt; {
      let transfer = this.fileTransfer.create();
      let path = "";
      let dir_name = 'Download';
      let file_name = "Sample.pdf";
  
      if (this.platform.is('ios')) {
        this.platform.ready().then(() =&gt; {
            path = this.file.documentsDirectory;
  
            this.file.writeFile(path,file_name,this.pdfSrc).then((entry) =&gt; {
              this.showAlert("download completed");
            }, (error) =&gt; {
              this.showAlert("Download Failed.");
            }).catch(err=&gt;{
              this.showAlert("Download Failed catch.");
              this.showAlert(err.message);
  
            });
          }
        )
      }
    };
  </code></pre>
  
  <p>Download completed alert shows and the downloaded path is: </p>
  
  <blockquote>
    <p>file:///var/mobile/Containers/Data/Application/6DE22F30-5806-4393-830A-14C8A1F320BE/Library/Cloud/Sample.pdf</p>
  </blockquote>
  
  <p>But i could not find that location in the device. Then, i google and saw <a href="https://github.com/apache/cordova-plugin-file" rel="noreferrer">here</a>.</p>
  
  <blockquote>
    <p>cordova.file.documentsDirectory - Files private to the app, but that
    are meaningful to other application (e.g. Office files). Note that for
    OSX this is the user's ~/Documents directory. (iOS, OSX)</p>
  </blockquote>
  
  <p>So, i can't see the file actually as it is private to the application. Then i saw in the same link:</p>
  
  <p><a href="https://i.stack.imgur.com/Hzjnp.png" rel="noreferrer"><img src="https://i.stack.imgur.com/Hzjnp.png" alt="enter image description here"></a></p>
  
  <p>So, i tried with the both preference in my config.xml but nothing happened.</p>
  
  <p>Is there any approach to download the file iOS or to dropbox or anywhere else?</p>