3. Native Apps Are the Best!
SO WHY ARE WE TALKING ABOUT HYBRID?
• Times Change
• Technology moves forward
4. 3 Classes of Hybrid App Platoforms
• The Wrapper
• Any Other Language
• Shared Code
5. What is not new?
BUT STILL AROUND AND GETTING UPDATES
• Phone Gap
• Ruby Motion
• Xamarin
6. PhoneGap
OR IS IT CORDOVA?
• Wrapper App
• HTML 5, JavaScript, CSS
• iOS, Android, Fire, Blackeberry 10, Firefox OS
• Ubuntu, Windows Phone 8, Tizen
• Adobe & Apache License
7. PhoneGap
“I think a big reason why PhoneGap was created is that we
wanted to get back to building web apps and using HTML, CSS
and JavaScript and not get locked in to a proprietary vendor
platform.”
8. Ruby Motion
• Any Other Language
• Ruby (obviously)
• iOS, Android, OS X
• Can use 3rd party frameworks on both platforms
• $16.5 a month, $29 a month, Enterprise
10. Xamarin
800LB GORILLA
• Any Other Language
• C#
• iOS, Android, OS X, Windows Phone
• 3rd party frameworks must be specially wrapped
“components”.
• $25 a month, $83 a month or $158 a month, per
developer per platform!
27. Go
1.5 RELEASE CANDIDATE
• Shared Code / Any Other Language
• Go (obviously)
• iOS, Android, OS X, Windows, Linux
• 3rd Party Frameworks - Yes
• Free
28. Go 1.5
HOW DOES IT WORK?
• Cross compilation
• Example: compiling for arm from amd64
• gomobile tool
29. gomobile
THIS IS WHERE WHERE THE MAGIC HAPPENS
go get golang.org/x/mobile/cmd/gomobile
Commands:
bind build a shared library for android APK and iOS app
build compile android APK and iOS app
init install android compiler toolchain
install compile android APK and install on device
version print version
30. gomobile
BUILD VS. BIND
• Your package must have a main function.
• Very limited “App” functionality.
• OpenGL, Audio, Sprites.
• No native UI.
• Not very useful at this point.
gomobile build -target=[ios | android ]
31. gomobile
BUILD VS. BIND
• Your package must not have a function.
• Android outputs an .aar archive.
• Wraps Java Native Interface (JNI).
• iOS outputs a .framework.
• Complete with Obj-C header files.
gomobile bind -target=[ios | android ]
40. Go Standard Library
MY GOD, IT’S FULL OF STARS
runtime
unicode/utf8
io
strings
crypto
html
time
image os
zip
sql
csv
json
xml mime
rand
template
mail
tls
http
testing
url
41. Go
DOWNSIDES
• Very early days.
• Only a subset of Go types are supported.
• int, float, string, bool
• functions, interfaces, structs
• Work in progress
• Debugging.
• Tooling
• Bitcode?
•