Making the Mobile Web Native with PhoneGap

  • 896 views
Uploaded on

Presented at SpringOne 2GX 2011

Presented at SpringOne 2GX 2011

More in: Technology
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
No Downloads

Views

Total Views
896
On Slideshare
0
From Embeds
0
Number of Embeds
1

Actions

Shares
Downloads
28
Comments
0
Likes
3

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Making the Mobile Web Native with PhoneGapRoy Clarkson and Keith DonaldSpringSource, a division of VMware, Inc.© 2011 SpringOne 2GX 2011. All rights reserved. Do not distribute without permission.
  • 2. Agenda• Introduction• Support for Android and iOS• PhoneGap API & Plugins• PhoneGap Build• Remote Debugging• html5expense reference app walk-through• Q&A2
  • 3. Introduction3
  • 4. What problem are we trying to solve?• Each device has a different native development SDK and associated programming language• For a variety of reasons, it may not be feasible to build and maintain multiple native apps• How can we reach all these different devices and app stores?4
  • 5. Native Development Environments5
  • 6. What is the solution?• Build your application using web standards like HTML5, CSS3, and JavaScript.• But what about accessing other features of the device, such as the camera or contacts list?6
  • 7. What is PhoneGap?“PhoneGap is an HTML5 app platform that allows you toauthor native applications with web technologies and getaccess to APIs and app stores. PhoneGap leverages webtechnologies developers already know best... HTML andJavaScript.” - phonegap.com7
  • 8. PhoneGap and Nitobi in the News• In October 2011, Adobe acquired Nitobi enabling the team to focus solely on the PhoneGap project and continue its work on efficient expressive design and development across devices.• The PhoneGap code was contributed to the Apache Software Foundation (ASF) under the name Apache Callback in October 2011. It is currently under incubation until it can become a full Apache project.8
  • 9. Support for iOS and Android9 © 2011 SpringOne 2GX 2011. All rights reserved. Do not distribute without permission.
  • 10. iOS Configuration• Mac OS X• Xcode 4• iOS simulator• PhoneGap• Xcode project template10
  • 11. Android Configuration• Eclipse• Android SDK• ADT Plugin for Eclipse• PhoneGap11
  • 12. Phonegap API and plugins12 © 2011 SpringOne 2GX 2011. All rights reserved. Do not distribute without permission.
  • 13. Phonegap Core Device APIs• Accelerometer• Camera / Media Capture• Connection• Compass• Contacts• Events / Notifications• File• Geolocation• Storage13
  • 14. Phonegap Core Device APIs (2)• API Documentation – http://docs.phonegap.com/en/1.1.0/• Source Code – Android: https://github.com/callback/callback-android – IOS: https://github.com/callback/callback-ios14
  • 15. Demo: Phonegap APIs15 © 2011 SpringOne 2GX 2011. All rights reserved. Do not distribute without permission.
  • 16. Phonegap Plugins• Moving toward “everything is a plugin” model• Core “plugins” included by default• New plugins can be added / developed in a consistent way – JavaScripts – Native bridging for each platform e.g .java• Source Code – https://github.com/phonegap/phonegap-plugins16
  • 17. Demo: Plugins17 © 2011 SpringOne 2GX 2011. All rights reserved. Do not distribute without permission.
  • 18. PhoneGap Build• Cross platform – iOS – Android – webOS – Symbian – BlackBerry• No local setup required• Supports Git• https://build.phonegap.com/18
  • 19. Demo Getting started with Phonegap Build https://build.phonegap.com https://github.com/kdonald/hello-phonegap19 © 2011 SpringOne 2GX 2011. All rights reserved. Do not distribute without permission.
  • 20. Debugging• Weinre – Debugger for web pages – Designed to work remotely – Debug web pages on a phone• Availability – http://debug.phonegap.com/ – http://phonegap.github.com/weinre/20
  • 21. Demo Remote debugging demo21 © 2011 SpringOne 2GX 2011. All rights reserved. Do not distribute without permission.
  • 22. html5expense walkthrough• Phonegap 1.1.0• jquery Mobile• Camera API• “Stopgap” for portability• PhoneGap build for native builds – Also created native projects so we can do local builds• Weinre for remote debugging• “Hydra” for dynamic update capability22
  • 23. Q&A23 © 2011 SpringOne 2GX 2011. All rights reserved. Do not distribute without permission.