added initial support for cordova