Skip to content

Instantly share code, notes, and snippets.

@edewit
Last active August 29, 2015 14:24
Show Gist options
  • Save edewit/00b2cca910df80c64517 to your computer and use it in GitHub Desktop.
Save edewit/00b2cca910df80c64517 to your computer and use it in GitHub Desktop.
# Clone an existing Feedhenry forms app
git clone <Feedhenry forms app>
APP_NAME=forms
# Create a new cordova project using the HTML, CSS and JavaScript of the forms app
cordova create $APP_NAME --copy-from <Feedhenry forms app>/www
cd $APP_NAME
cordova platform add windows
# Install the jscompat to be able to have dynamic content
cd ..
git clone https://github.com/MSOpenTech/winstore-jscompat.git
cp winstore-jscompat/winstore-jscompat.js $APP_NAME/www
# Install the 'default' plugins
cd $APP_NAME
cordova plugin add org.apache.cordova.device
cordova plugin add org.apache.cordova.network-information
cordova plugin add org.apache.cordova.battery-status
cordova plugin add org.apache.cordova.device-motion
cordova plugin add org.apache.cordova.device-orientation
cordova plugin add org.apache.cordova.geolocation
cordova plugin add org.apache.cordova.file
cordova plugin add org.apache.cordova.camera
cordova plugin add org.apache.cordova.media
cordova plugin add org.apache.cordova.media-capture
cordova plugin add org.apache.cordova.file-transfer
cordova plugin add org.apache.cordova.dialogs
cordova plugin add org.apache.cordova.vibration
cordova plugin add org.apache.cordova.contacts
cordova plugin add org.apache.cordova.globalization
cordova plugin add com.feedhenry.plugins.splashscreen
cordova plugin add org.apache.cordova.inappbrowser
cordova plugin add org.apache.cordova.console
vim www/index.html
# add <script src="winstore-jscompat.js"></script> into the head of the document
@edewit
Copy link
Author

edewit commented Jul 23, 2015

add <script src="cordova.js"></script> into the head of the document

cordova plugin add https://github.com/fheng/fh-cordova-plugins-api.git

Bug fixes

feedhenry/fh-js-sdk#128
https://github.com/fheng/fh-cordova-plugins-api/pull/3
feedhenry/fh-js-sdk#129

@kpiwko
Copy link

kpiwko commented Jul 23, 2015

Steps I've done apart from ones in the tutorial:

  1. build fh-js-sdk from source via grunt command, replaced feedhenry.js in the app with dist/feedhenry-forms.js
  2. added fh-cordova-plugins-api via cordova plugin add https://github.com/edewit/fh-cordova-plugins.git#windows

Added <script src="cordova.js"></script> prior winstore-jscompat.js or after.

This, application does not run smoothly.

@kpiwko
Copy link

kpiwko commented Jul 23, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment