-
Notifications
You must be signed in to change notification settings - Fork 0
Development Setup
Jeremy Hewett edited this page Jun 23, 2014
·
21 revisions
- Install NodeJS
- Install Git
- Install Ionic
>npm install -g cordova ionic
- http://ionicframework.com/getting-started/
- Install the iOS SDK
- Clone this repository
>git clone https://github.com/jeremyhewett/HealthMeasures.git
- Add the iOS platform to the Ionic project
- Navigate to the cloned repository in a command prompt.
>ionic platform add ios
- Build and run the project
>ionic build ios
>ionic emulate ios
Building the Ionic project and loading it in a device emulator takes time. For a quicker turn-around time during development, the app can be tested in Chrome.
- Install the Ripple add-on for Chrome
- Adjust Dependencies
- Comment out
<script src="cordova.js"></script>
inindex.html
- Copy
config.xml
from the root of the project directory to/www/
- Run a web server
- The easiest way to do this is to use the Ionic server by running
>ionic serve
which creates a server at http://localhost:8100. This server automatically refreshes the page when files are changed.
- Activate the Ripple emulator plugin in Chrome.
NOTE: Unfortunately it seems at this stage Ripple on supports up to Cordova 2.0.0
- Uncaught Object error in Chrome
- This is cause by long error strings not being displayed properly by Chrome. http://jsfiddle.net/jeremyhewett/8FE6a/
- They are probably coming from
ionic.bundle.js
line 9070. Just addconsole.log(message)
before that line to see the errors. (Remember this will also log caught errors which are not necessarily a problem.)
- Install Java SDK
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_05
- Install Apache Ant
ANT_BIN=C:\Program Files\Apache\apache-ant-1.9.4\bin
- Add
ANT_BIN
to path variable. ANT_HOME=C:\Program Files\Apache\apache-ant-1.9.4
- Install Android SDK
ANDROID_HOME=C:\Program Files\Android\android-sdk
ANDROID_PLATFORM_TOOLS=C:\Program Files\Android\android-sdk\platform-tools
ANDROID_TOOLS=C:\Program Files\Android\android-sdk\tools
- Add all 3 to path variable.
- Build project
>ionic platform add android
>ionic build android