Cordova File Handler plugin

Usage no npm install needed!

<script type="module">
  import cordovaPluginShaggyFilehandler from '';


Cordova Filehandler Plugin

The plugin shall make it easy for developers to handle files (e.g. let the user select/delete files, copy files).

This is a project done in spare time. We hope to extend it as much (and as fast) as possible, as we also have to study and work.

Install with Cordova CLI

cordova plugin add


shaggy.filehandler returns a new FileHandler object. The object currently (2018.07.21) has the following methods:

choose(successCallback, failureCallback, options);



let filehandler = shaggy.filehandler;
function success(files)
  let uris = files.uris; //array of selected uris   
   //You can now work with the uris, to access the selected files.
  for(uri in uris)
       function a(f){...},
       function b(e){...});

function error(message)
  console.log("Got the following error: " + error);

let options  =
  types : ["*/*"], //array of strings
  num   : 0 // 0 (unlimited) and 1 supported
  persistent: false, //Not yet supported
  title : "Choose files(s)"
filehandler.choose(success, error, options);