Need help upgrading to Ionic Framework 4.0? Get assistance with our Enterprise Migration Services EXPLORE NOW

iOS File Picker

Improve this doc

Opens the file picker on iOS for the user to select a file, returns a file URI.

Repo: https://github.com/jcesarmobile/FilePicker-Phonegap-iOS-Plugin

Installation

  1. Install the Cordova and Ionic Native plugins:
    $ ionic cordova plugin add cordova-plugin-filepicker
    $ npm install --save @ionic-native/file-picker@4
    
  2. Add this plugin to your app's module

Supported platforms

Usage

import { IOSFilePicker } from '@ionic-native/file-picker';

constructor(private filePicker: IOSFilePicker) { }

...

this.filePicker.pickFile()
  .then(uri => console.log(uri))
  .catch(err => console.log('Error', err));

Instance Members

pickFile()

Open a file

Returns: Promise<string>

IOSFilePickerPosition

Param Type Details
x number
y number
width number
height number

API

Native

General