This is a generic app framework with polymer ui elements that can run as a standalone webpage, an android app, or an ios app.
This demo provides basic application scaffolding using polymer.
In addition to
- Clone this repo and delete the .git directory
- Update the application name in bower.json and package.json
- Follow the steps below to get the boilerplate app working.
- run
npm install -g yoto install yo, grunt-cli and bower - run
npm install -g cordovato install the cordova mobile utility - run
export PATH=/usr/local/share/npm/bin:$PATHto ensure command line access to modules.
- run
npm installto initialize node modules - run
bower installto initialize bower dependencies - run
grunt buildto build the "dist" directory - run
grunt cordovato build the cordova directory
Run this the first time, and any time after you make modifications to the app
directory.
- run
grunt cordovato initialize the platforms directory with ios and android applications
- grunt serve --platform=ios
The android app can be run in an emulator, which can be installed with brew
- run
brew install androidto install the android toolkig - run
androidto download packages and set up an avd device.
To run the android on an emulator or connected device
- Attach an android device in debug mode, or run the android avd emulator.
- if you are running on a connected device you can verify first with
adb devices cd cordova- run
cordova run android
TODO
The ios app can be run in an emulator, which can be installed via xcode. It can only be installed on devices with a valid provisioning profile, which requires a paid apple developer account.
To run on a emulator
cd cordova- run
cordova emulate ios
To run on a connected device (requires provisioning)
- run
cordova run ios
- Run Xcode
- Open
./platforms/ios/*.xcodeproj - Click Run
- At the command line run
defaults write com.apple.Safari IncludeDebugMenu 1(you only need to do this once) - Launch the app in the emulator
- Launch safari
- Connect to the Iphone Simulator in the Develop menu
- Find a module with
bower search <search term> - Install it and save it to your bower.json file with
bower install <javascript module> --save
README.mdThis filebower.jsonA list of all json dependencies. Do not modify directly.
Add new dependencies withbower install <dependency name> --saveapp/All of the actual content of the app is contained in this directory
dist/*Stores the intermediate minified and cleaned files before they are compiled to cordovacordova/*Stores the generated cordova applications for ios and androidnode_modules/*These files are generaetd by npm installapp/bower_components/*These files are generated by bower install


