CROSS PLATFORM MOBILE APPS WITH PHONEGAP CHRISTOPHE COENRAETS - - PowerPoint PPT Presentation

cross platform mobile apps with phonegap
SMART_READER_LITE
LIVE PREVIEW

CROSS PLATFORM MOBILE APPS WITH PHONEGAP CHRISTOPHE COENRAETS - - PowerPoint PPT Presentation

CROSS PLATFORM MOBILE APPS WITH PHONEGAP CHRISTOPHE COENRAETS ADOBE @CCOENRAETS HTTP://COENRAETS.ORG h t ps://github.com/ccoenraets N Platforms = N Apps Objective-C Java NDK J2ME C# C++ C++ C/C++ N = 1 ? Objective-C Java NDK J2ME


slide-1
SLIDE 1

ADOBE @CCOENRAETS HTTP://COENRAETS.ORG

CHRISTOPHE COENRAETS

CROSS PLATFORM MOBILE APPS WITH PHONEGAP

slide-2
SLIDE 2

htps://github.com/ccoenraets

slide-3
SLIDE 3 Objective-C Java NDK C# J2ME C/C++ C++ C++

N Platforms = N Apps

slide-4
SLIDE 4

N = 1 ?

slide-5
SLIDE 5 Objective-C Java NDK C# J2ME C/C++ C++ C++
slide-6
SLIDE 6 Objective-C Java NDK C# J2ME C/C++ C++ C++
slide-7
SLIDE 7

Package as Native App Access device features

Mobile Sites Mobile Apps

slide-8
SLIDE 8

Hybrid Apps

C/C++ C++ C++ C# J2ME Java Objective-C

slide-9
SLIDE 9

Accessing Device Features

JavaScript OS

slide-10
SLIDE 10

User Experience Platforms

slide-11
SLIDE 11

Is this an App?

slide-12
SLIDE 12

Hybrid App Native App Access App Store App Store Updates App Store + Instant App Store Graphic HTML, Canvas, SVG Native Performance Slower * Faster * Device APIs Yes No Language Web Objective C / Java / C Connectivity Online / Offline Online / Offline Push Notification Yes Yes

slide-13
SLIDE 13

PhoneGap Performance

  • 1. Keep small footprint (and avoid unneeded libs)
  • 2. Use Tap events, not Click events
  • 3. Use hardware accelerated CSS transitions
slide-14
SLIDE 14

BBC Olympics

slide-15
SLIDE 15

Untappd

slide-16
SLIDE 16

Salesforce.com Logger

slide-17
SLIDE 17

Building Hybrid Apps

PhoneGap Build

ipa apk OTA xap wgz ipk

+ +

slide-18
SLIDE 18

ARCHITECTING HYBRID APPS

slide-19
SLIDE 19

Old School: UI generated at the server-side in PHP, JSP, ASP, RoR, CF, ...

slide-20
SLIDE 20

<html> <head> <title>Huge App</title> <script src="huge-app.js"></script> </head> <body></body> </html>

New School: Single Page Application UI built dynamically at the client-side in JavaScript

slide-21
SLIDE 21

Framework Landscape

DOM Architecture UI Full stack Custom stack

slide-22
SLIDE 22

Router

Router = Backbone.Router.extend({ routes: { "" : "list", "employees/:id" : "details” }, list: function() { $('#list').html('<div>Employee List</div>'); }, details: function(id) { $('#details').html('<div>Employee Details</div>'); } });

slide-23
SLIDE 23

View

EmployeeView = Backbone.View.extend({ template: _.template($('#employee-tpl').html()), initialize: function () { this.render(); }, events: { "click .save": "save" }, render: function () { $(this.el).html(this.template(this.model.toJSON())); }, save: function () { this.model.save({firstName: $('#firstName').val()}); } });

slide-24
SLIDE 24

Model

Employee = Backbone.Model.extend({ urlRoot: "api/employees" }); emp = new Employee({firstName: 'Joe', lastName: 'Smith'}); emp.save();

slide-25
SLIDE 25

@ccoenraets htp://coenraets.org