Web and Native in 2012

857 views

Published on

A selection of interesting projects at the bleeding edge of hybrid/chimera mobile apps.

Presented at Droidcon India, 2012 on 2 November 2012.

Published in: Technology
  • Be the first to comment

  • Be the first to like this

Web and Native in 2012

  1. 1. Web plus Native in 2012 @jhugman – James Hugman
  2. 2. Who is this guy? • Software Engineer • Programming: 20y, Mobile: 4y • Won awards for apps • Technology agnostic@jhugman
  3. 3. Order of Ceremonies • Latest results in Web v Native • Issues in cross platform development • Interesting projects • Predictions@jhugman
  4. 4. Web vs Native • Web: Developer friendly (except, when it’s not) • Native: User friendly (except, when it’s not)@jhugman
  5. 5. Web • Cross platform* • Existing libraries • Faster to develop* • Buzzword compliant • Massive developer mindshare@jhugman * Caveat emptor
  6. 6. Native • Better user experience • Tight device integration@jhugman
  7. 7. Gartner Hype Cycle Peak of Inflated Expectations Plateau of Productivity Slope of Enlightenment Trough of Disillusion Technology Trigger@jhugman
  8. 8. Cross-platform fallacies • “Write Once, Run Anywhere” • HTML5 is the answer@jhugman
  9. 9. Web based UIs • PhoneGap • Trigger.io@jhugman
  10. 10. Building UI with HTML • Webkit fragmentation • Desktop ≠ Mobile • High profile failures@jhugman
  11. 11. Write Once, Run Anywhere • UI metaphors differ between platforms • Negative messages to users: • “We don’t care [enough] about you”@jhugman
  12. 12. Important exceptions • When app is document focused • When utility trumps usability • Games@jhugman
  13. 13. Why Cross Platform? • For developers: • Less to learn • Less code to write • For business: • Lower cost of ownership@jhugman
  14. 14. Why Cross Platform*… Sucks? • For developers fewer tools • For users UX is compromised • For designers Design is compromised@jhugman
  15. 15. Something better • Native, platform specific UIs • Share as much other code as possible@jhugman
  16. 16. Architecture Sketch Presentation Layer Application Logic Layer Native API Layer@jhugman
  17. 17. Architecture Sketch • Implementation language • Execution language@jhugman
  18. 18. Technologies • Titanium JS • Ejecta UI in code • Kirin Portable Biz Logic • Calatrava • j2ObjC@jhugman
  19. 19. Javascript based
  20. 20. Building UI in Code Presentation Layer implemented in Javascript Application Logic Javascript Native APIs Native@jhugman
  21. 21. Titanium • The big hitter • Implement everything in Javascript • Execute UI in native@jhugman
  22. 22. Titanium + Good coverage of native APIs + Reasonable docs - Implement UI in JS, so crappy tools - Lists are hard to get right - Not easy to style@jhugman
  23. 23. Ejecta • HTML <canvas> and <audio> APIs • Implement in Javascript • Executed using native OpenGL and OpenAL@jhugman
  24. 24. Ejecta + Lots of existing libraries (e.g. Three.js, processing.js) + Faster than WebView’s <canvas> - Incomplete APIs for Graphics & Audio - iOS and Web only@jhugman
  25. 25. Honourable mention • MonoTouch & MonoDroid@jhugman
  26. 26. Mixed languages
  27. 27. Heterogenous Teams • Multiple people • Different skill sets • Only small overlaps in skill sets@jhugman
  28. 28. Shared App Logic Presentation Layer implemented in native Application Logic shared Native APIs Native@jhugman
  29. 29. Shared App Logic Obj-C Java HTML Application Logic shared@jhugman
  30. 30. Calatrava • Application logic in Javascript • Rubyist & Web developers version • Progressively enhance screens@jhugman
  31. 31. Calatrava + Start with HTML. Switch to native when needed. - Limited interaction between JS & Native - Not very extensible - Limited access to APIs - Bundles a JS engine per app@jhugman
  32. 32. Shared App Logic Your Obj-C Your Java Calatrava Your Shared Javascript@jhugman
  33. 33. Shared App Logic Your Obj-C Your Java Kirin Your Shared Javascript@jhugman
  34. 34. Kirin • Native mobile developers version • Designed for multi-disciplinary teams • Designed to be friendly to both ecosystems@jhugman
  35. 35. Kirin + Very extensible + Built on top of node.js and npm. - Limited access to APIs (currently)@jhugman
  36. 36. Shared App Logic Presentation Layer implemented in native Application Logic shared Native APIs Native@jhugman
  37. 37. j2ObjC • Java -> Objective C compiler • Google 20% project • Write in Java, execute natively on two platforms@jhugman
  38. 38. j2ObjC + GWT + Great tooling + Very extensible - Alpha release; Buggy - Not a tool suite@jhugman
  39. 39. Predictions • HTML5 on mobile will get better, slowly • Good but not great cross-platform solutions continue in small shops • Building multiple native clients will be accepted as the cost of doing business@jhugman
  40. 40. Summary • Business need will drive cross- platform • HTML UIs still difficult to make nice • Fertile ground for experimentation@jhugman
  41. 41. ThanksJames Hugman – @jhugman
  42. 42. Links • Titanium: appcelerator.com • Ejector.js: impactjs.com/ejecta/ overview • Calatrava: calatrava.github.com • Kirin: github.com/kirinjs/kirin • j2objc: code.google.com/p/j2objc@jhugman
  43. 43. Questions?@jhugman

×