Onegini Cordova Example app

This app serves as a simple example for building an app using the Onegini Cordova Plugin.

Source structure

This app is build with the Vue.js framework. Every view has it's own component in src/views, containing all it's HTML, JS and CSS. Components (like buttons or lists for specific items) are located in src/components.

Running the Example app

Prerequisites

To run the Example App, you need to be able to build Cordova apps for Android and iOS on your machine. Refer to the Apache Cordova getting started guide if you need help setting up your Cordova environment.

Make sure you have the SDK Configurator installed in your $PATH. (See the getting started guide of the Onegini Cordova Plugin)

Finally you need to have a valid Token Server configuration. We have already set you up with this, so you are good to go here :-). In order to see what the options are to supply the Token Server configuration see the getting started guide.

Building

Clone this repository

git clone https://github.com/onewelcome/example-app-cordova.git
cd example-app-cordova

Build www assets

npm install
npm run build

Add the Android and/or iOS platform

cordova platform add (android|ios)...

Run the example app

cordova run (android|ios)...

Possible Android Compile Error Due to a bug in the Android Gradle Plugin you might end up with the following compile error: "Unsupported class file major version 59"

Add the following setting to your gradle.properties file:

android.jetifier.ignorelist = bcprov-jdk15on

Or to add to add such Gradle property to the Cordova build you can pass the additional param to the Cordova run/build command:

cordova run android -- --gradleArg=-Pandroid.jetifier.ignorelist=bcprov-jdk15on