Appcelerator Titanium Intro

Nic Jansma
     @NicJ
 //nicj.net
Who am I?
Nic Jansma

Spent 6 years as a dev at Microsoft - Win 7 & IE 9/10 Perf Teams

Recently founded Wolverine Digital

Developing high-performance websites and apps

          nic@nicj.net     @NicJ      http://nicj.net
                http://github.com/nicjansma
First Two Apps (Native Android)




    Minifig Collector (free)   TiskTasks for Todoist ($0.99)
 http://minifigcollector.com       http://tisktasks.com
3rd    App
• October 2011: Partnered with the
  author of the Unofficial LEGO
  Minifigure Catalog to create an
  interactive version of his book

• Wanted to release on iOS and Android

• Native? PhoneGap? Appcelerator?
Native Development

Java       Objective-C
Appcelerator Titanium Mobile
• Titanium is a JavaScript runtime that gives you native access
  to the platform’s controls

• You are not building a app via html/css/js (i.e. PhoneGap)


                       JavaScript
How Titanium Mobile Works
• You write code in JavaScript

• At runtime, your application has 3 major components:
   o JavaScript source code (minified and inlined, but not compiled, into Java/Obj-C strings)
   o Titanium API implementation in the native OS
   o JavaScript interpreter (V8/Rhino for Android, JavaScriptCore for iOS)


• The JavaScript interpreter runs your JavaScript code in an
  environment with proxies for the native objects (windows,
  controls, etc)
Getting Titanium Mobile
Step 1: Sign up for Appcelerator
• https://my.appcelerator.com/auth/signup
• “App EXPLORE” plan = Free: Build, test, ship, sell for free
• Additional plans available (more analytics, cloud, support):
   http://www.appcelerator.com/plans-pricing

Step 2: Download Titanium Studio
• http://www.appcelerator.com/platform/titanium-studio

Step 3:
• Profit ???
Titanium Studio
• Eclipse-- (was
  Aptana Studio)
• Editor
• Formatting
• Code-completion
• Build
• Debug
• Release
App File Structure
• I18n - Internationalization files
• modules - Third-Party (or Appcelerator) native modules
• Resources
   o app.js – Startup file
   o images - Generic Images
   o android - Android-specific images
        • imageshigh / etc – Android density/screen-size dirs
   o iphone - iOS-specific images
        • @2x files
   o lib, ui, whatever - your source file dirs
Hello World
var win = Ti.UI.createWindow({
    title: 'Hello, World!',
    layout: 'vertical',
    backgroundColor: 'white'
});

var helloLabel = Ti.UI.createLabel({
    text: 'Hello World',
    color: 'black',
    font: {
        fontSize: '20sp'
    },
    height: '40dp',
    width: '250dp'
});
win.add(helloLabel);

var helloButton = Ti.UI.createButton({
    title: 'Click me!',
    font: {
        fontSize: '20sp'
    },
    top: '20dp',
    height: '40dp',
    width: '250dp'
});

helloButton.addEventListener('click', function() {
    alert('you clicked me!');
});
win.add(helloButton);

win.open();
Titanium Mobile APIs
•   AJAX / Web services
•   In-App Purchases
•   Geolocation
•   Camera
•   Media / Photo Gallery
•   Accelerometer
•   Maps
•   Analytics
•   Social Sharing (Facebook, etc)

• Extensible with your own native iOS/Android packages
KitchenSink
• https://github.com/appcelerator/KitchenSink/
Cloud Services
• http://www.appcelerator.com/cloud
Future Platform Support
• Blackberry
• WinPhone7
Pros
• One codebase for two platforms
    o You’ll (theoretically) spend less time than writing two native apps
    o Maintenance on one codebase should be easier in the long run


• Native interface controls
    o Your apps can look just like native ones


• Might be able to reuse your JavaScript in other parts of your project
    o eg., Web front-end, Node.js backend


• Platform is open-source
    o https://github.com/appcelerator/titanium_mobile


• JavaScript is fun!
Cons
• Platform is young and still changing

• Need to learn a new platform / SDK / quirks
    o Knowing the ins & outs of native iOS / Android will help


• You’ll still have lots of if(iOS){} and if(android){}
    o LEGO Minifig Collector has 24 blocks of code that are Android or iOS specific


• Performance isn’t 100% of a native app

• SDK/API Documentation is weak (but getting better)

• Q&A support forum is a mess (use SO instead)
Unofficial LEGO Minifigure
            Catalog
• Took ~1 month to develop

• http://minifigure.org/application

• Releasing content updates via IAP

• Got featured in iTunes Catalogs
  category for a week

• Looking back, Titanium was the
  right choice for our product’s needs
Lessons Learned
• I probably spent as much time learning Titanium and building my
  first app as I would have spent learning native iOS
    o Now I can build apps in Titanium quickly, but still need to learn native iOS
    o 2nd+ Titanium app will be a lot easier to build

• It takes time to ramp-up on good JavaScript patterns
    o CommonJS modules, Crockford-isms, http://shichuan.github.com/javascript-patterns/

• I like JavaScript
    o Now I’m developing a game where JavaScript is the whole stack: Node.js websockets and HTTP
      server, frontend in HTML/CSS/JS, mobile version via Titanium

• iOS simulator is a lot faster to test on. Android emulator is slow!

• For community support, you’ll need to use a combination of the
  Appcelerator API Docs, Q&A site, videos and StackOverflow
Lessons Learned, continued
• You’ll spend time adapting when they release SDK updates
          o 1.7.x => 1.8.x: Took me 2 days to find and fix bugs from SDK changes


• You won’t double your sales just by releasing on both
  platforms
        4500

        4000

        3500

        3000

        2500
Units




        2000

        1500

        1000

        500

           0
                                 iOS                                       Android
Good Reads
Links
Appcelerator
• http://appcelerator.com
• http://docs.appcelerator.com/titanium/2.1/index.html
• http://developer.appcelerator.com/questions/newest
• http://stackoverflow.com/questions/tagged/titanium
• http://vimeo.com/appcelerator

Community Projects
• Joli https://github.com/xavierlacot/joli.js/
1 of 22

Recommended

Appcelerator Titanium Intro (2014) by
Appcelerator Titanium Intro (2014)Appcelerator Titanium Intro (2014)
Appcelerator Titanium Intro (2014)Nicholas Jansma
7.8K views29 slides
Getting started with Appcelerator Titanium by
Getting started with Appcelerator TitaniumGetting started with Appcelerator Titanium
Getting started with Appcelerator TitaniumTechday7
2K views51 slides
Titanium Appcelerator - Beginners by
Titanium Appcelerator - BeginnersTitanium Appcelerator - Beginners
Titanium Appcelerator - BeginnersAmbarish Hazarnis
6.1K views38 slides
Introduction to Appcelerator Titanium by
Introduction to Appcelerator TitaniumIntroduction to Appcelerator Titanium
Introduction to Appcelerator TitaniumAdam Paxton
2K views22 slides
Appcelerator Titanium - An Introduction to the Titanium Ecosystem by
Appcelerator Titanium - An Introduction to the Titanium EcosystemAppcelerator Titanium - An Introduction to the Titanium Ecosystem
Appcelerator Titanium - An Introduction to the Titanium EcosystemBoydlee Pollentine
2.6K views22 slides
Cordova + Ionic + MobileFirst by
Cordova + Ionic + MobileFirstCordova + Ionic + MobileFirst
Cordova + Ionic + MobileFirstRaymond Camden
3.4K views163 slides

More Related Content

What's hot

How React Native, Appium and me made each other shine @ContinuousDeliveryAmst... by
How React Native, Appium and me made each other shine @ContinuousDeliveryAmst...How React Native, Appium and me made each other shine @ContinuousDeliveryAmst...
How React Native, Appium and me made each other shine @ContinuousDeliveryAmst...Wim Selles
143 views83 slides
Overview of DroidCon UK 2015 by
Overview of DroidCon UK 2015 Overview of DroidCon UK 2015
Overview of DroidCon UK 2015 Elif Boncuk
418 views80 slides
ReactJS by
ReactJSReactJS
ReactJSFatih Şimşek
331 views26 slides
Apps with Apache Cordova and Phonegap by
Apps with Apache Cordova and PhonegapApps with Apache Cordova and Phonegap
Apps with Apache Cordova and PhonegapChristian Grobmeier
29.7K views33 slides
Droidcon de 2014 google cast by
Droidcon de 2014   google castDroidcon de 2014   google cast
Droidcon de 2014 google castDroidcon Berlin
2.2K views40 slides
TiConf EU 2014 by
TiConf EU 2014TiConf EU 2014
TiConf EU 2014Ingo Muschenetz
4.7K views54 slides

What's hot(20)

How React Native, Appium and me made each other shine @ContinuousDeliveryAmst... by Wim Selles
How React Native, Appium and me made each other shine @ContinuousDeliveryAmst...How React Native, Appium and me made each other shine @ContinuousDeliveryAmst...
How React Native, Appium and me made each other shine @ContinuousDeliveryAmst...
Wim Selles143 views
Overview of DroidCon UK 2015 by Elif Boncuk
Overview of DroidCon UK 2015 Overview of DroidCon UK 2015
Overview of DroidCon UK 2015
Elif Boncuk418 views
App forum2015 London - Building RhoMobile Applications with Ionic by robgalvinjr
App forum2015 London - Building RhoMobile Applications with IonicApp forum2015 London - Building RhoMobile Applications with Ionic
App forum2015 London - Building RhoMobile Applications with Ionic
robgalvinjr824 views
Appium Meetup #2 - Mobile Web Automation Introduction by snevesbarros
Appium Meetup #2 - Mobile Web Automation IntroductionAppium Meetup #2 - Mobile Web Automation Introduction
Appium Meetup #2 - Mobile Web Automation Introduction
snevesbarros1.3K views
NCDevCon 2017 - Cross Platform Mobile Apps by John M. Wargo
NCDevCon 2017 - Cross Platform Mobile AppsNCDevCon 2017 - Cross Platform Mobile Apps
NCDevCon 2017 - Cross Platform Mobile Apps
John M. Wargo448 views
Appium workshop technopark trivandrum by Syam Sasi
Appium workshop technopark trivandrumAppium workshop technopark trivandrum
Appium workshop technopark trivandrum
Syam Sasi1.4K views
Ionic Mobile Applications - Hybrid Mobile Applications Without Compromises by Jacob Friesen
Ionic Mobile Applications - Hybrid Mobile Applications Without CompromisesIonic Mobile Applications - Hybrid Mobile Applications Without Compromises
Ionic Mobile Applications - Hybrid Mobile Applications Without Compromises
Jacob Friesen2.4K views
Lesson 02 - React Native Development Environment Setup by University of Catania
Lesson 02 - React Native Development Environment SetupLesson 02 - React Native Development Environment Setup
Lesson 02 - React Native Development Environment Setup
Mobile WebDriver Selendroid by Dominik Dary
Mobile WebDriver SelendroidMobile WebDriver Selendroid
Mobile WebDriver Selendroid
Dominik Dary29K views
Introduction to Apache Cordova (Phonegap) by ejlp12
Introduction to Apache Cordova (Phonegap)Introduction to Apache Cordova (Phonegap)
Introduction to Apache Cordova (Phonegap)
ejlp1232.4K views
Appium Mobile Testing: Nakov at BurgasConf - July 2021 by Svetlin Nakov
Appium Mobile Testing: Nakov at BurgasConf - July 2021Appium Mobile Testing: Nakov at BurgasConf - July 2021
Appium Mobile Testing: Nakov at BurgasConf - July 2021
Svetlin Nakov137 views
10 Golden Rules For Outstanding Titanium Apps by jamessugrue
 10 Golden Rules For Outstanding Titanium Apps 10 Golden Rules For Outstanding Titanium Apps
10 Golden Rules For Outstanding Titanium Apps
jamessugrue8.3K views
Ti.conf titanium on firefoxos by Alessio Ricco
Ti.conf titanium on firefoxosTi.conf titanium on firefoxos
Ti.conf titanium on firefoxos
Alessio Ricco3.9K views
Lotusphere 2011 Jmp103 - Jumpstart Your "Jedi Plug-in Development Skills" wi... by Ryan Baxter
Lotusphere 2011  Jmp103 - Jumpstart Your "Jedi Plug-in Development Skills" wi...Lotusphere 2011  Jmp103 - Jumpstart Your "Jedi Plug-in Development Skills" wi...
Lotusphere 2011 Jmp103 - Jumpstart Your "Jedi Plug-in Development Skills" wi...
Ryan Baxter1.6K views

Viewers also liked

An introduction to Titanium by
An introduction to TitaniumAn introduction to Titanium
An introduction to TitaniumGraham Weldon
2.8K views67 slides
大なごやJS vol.6 Titanium Mobile と Alloy の解説をするよ! by
大なごやJS vol.6 Titanium Mobile と Alloy の解説をするよ!大なごやJS vol.6 Titanium Mobile と Alloy の解説をするよ!
大なごやJS vol.6 Titanium Mobile と Alloy の解説をするよ!Mori Shingo
6.6K views31 slides
Appcelerator Titanium at Mobile 2.0 by
Appcelerator Titanium at Mobile 2.0Appcelerator Titanium at Mobile 2.0
Appcelerator Titanium at Mobile 2.0Jeff Haynie
2.4K views38 slides
Building Rich Applications with Appcelerator by
Building Rich Applications with AppceleratorBuilding Rich Applications with Appcelerator
Building Rich Applications with AppceleratorMatt Raible
2.6K views37 slides
Aplicações nativas para iOS e Android com JavaScript e Titanium Mobile by
Aplicações nativas para iOS e Android com JavaScript e Titanium MobileAplicações nativas para iOS e Android com JavaScript e Titanium Mobile
Aplicações nativas para iOS e Android com JavaScript e Titanium MobileGuilherme Chapiewski
29.1K views29 slides
Using Modern Browser APIs to Improve the Performance of Your Web Applications by
Using Modern Browser APIs to Improve the Performance of Your Web ApplicationsUsing Modern Browser APIs to Improve the Performance of Your Web Applications
Using Modern Browser APIs to Improve the Performance of Your Web ApplicationsNicholas Jansma
4.3K views37 slides

Viewers also liked(16)

An introduction to Titanium by Graham Weldon
An introduction to TitaniumAn introduction to Titanium
An introduction to Titanium
Graham Weldon2.8K views
大なごやJS vol.6 Titanium Mobile と Alloy の解説をするよ! by Mori Shingo
大なごやJS vol.6 Titanium Mobile と Alloy の解説をするよ!大なごやJS vol.6 Titanium Mobile と Alloy の解説をするよ!
大なごやJS vol.6 Titanium Mobile と Alloy の解説をするよ!
Mori Shingo6.6K views
Appcelerator Titanium at Mobile 2.0 by Jeff Haynie
Appcelerator Titanium at Mobile 2.0Appcelerator Titanium at Mobile 2.0
Appcelerator Titanium at Mobile 2.0
Jeff Haynie2.4K views
Building Rich Applications with Appcelerator by Matt Raible
Building Rich Applications with AppceleratorBuilding Rich Applications with Appcelerator
Building Rich Applications with Appcelerator
Matt Raible2.6K views
Aplicações nativas para iOS e Android com JavaScript e Titanium Mobile by Guilherme Chapiewski
Aplicações nativas para iOS e Android com JavaScript e Titanium MobileAplicações nativas para iOS e Android com JavaScript e Titanium Mobile
Aplicações nativas para iOS e Android com JavaScript e Titanium Mobile
Guilherme Chapiewski29.1K views
Using Modern Browser APIs to Improve the Performance of Your Web Applications by Nicholas Jansma
Using Modern Browser APIs to Improve the Performance of Your Web ApplicationsUsing Modern Browser APIs to Improve the Performance of Your Web Applications
Using Modern Browser APIs to Improve the Performance of Your Web Applications
Nicholas Jansma4.3K views
Using Phing for Fun and Profit by Nicholas Jansma
Using Phing for Fun and ProfitUsing Phing for Fun and Profit
Using Phing for Fun and Profit
Nicholas Jansma3.8K views
The Happy Path: Migration Strategies for Node.js by Nicholas Jansma
The Happy Path: Migration Strategies for Node.jsThe Happy Path: Migration Strategies for Node.js
The Happy Path: Migration Strategies for Node.js
Nicholas Jansma6.7K views
Forensic Tools for In-Depth Performance Investigations by Nicholas Jansma
Forensic Tools for In-Depth Performance InvestigationsForensic Tools for In-Depth Performance Investigations
Forensic Tools for In-Depth Performance Investigations
Nicholas Jansma4.1K views
Html5 devconf nodejs_devops_shubhra by Shubhra Kar
Html5 devconf nodejs_devops_shubhraHtml5 devconf nodejs_devops_shubhra
Html5 devconf nodejs_devops_shubhra
Shubhra Kar841 views
Measuring the Performance of Single Page Applications by Nicholas Jansma
Measuring the Performance of Single Page ApplicationsMeasuring the Performance of Single Page Applications
Measuring the Performance of Single Page Applications
Nicholas Jansma16.7K views
Measuring Real User Performance in the Browser by Nicholas Jansma
Measuring Real User Performance in the BrowserMeasuring Real User Performance in the Browser
Measuring Real User Performance in the Browser
Nicholas Jansma11.5K views

Similar to Appcelerator Titanium Intro

Intro to Appcelerator Titanium - Code for Fort Lauderdale 2015 by
Intro to Appcelerator Titanium - Code for Fort Lauderdale 2015Intro to Appcelerator Titanium - Code for Fort Lauderdale 2015
Intro to Appcelerator Titanium - Code for Fort Lauderdale 2015Adam Paxton
1.4K views25 slides
Mobile native-hacks by
Mobile native-hacksMobile native-hacks
Mobile native-hacksDevelopmentArc LLC
707 views29 slides
Mobile ECM with JavaScript - JSE 2011 by
Mobile ECM with JavaScript - JSE 2011Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011Nuxeo
865 views56 slides
The Big Easy: Native Mobile App Development with Appcelerator Titanium and Ja... by
The Big Easy: Native Mobile App Development with Appcelerator Titanium and Ja...The Big Easy: Native Mobile App Development with Appcelerator Titanium and Ja...
The Big Easy: Native Mobile App Development with Appcelerator Titanium and Ja...Adam Paxton
917 views30 slides
Titanium Mobile by
Titanium MobileTitanium Mobile
Titanium MobileAxway Appcelerator
417 views20 slides
State ofappdevelopment by
State ofappdevelopmentState ofappdevelopment
State ofappdevelopmentgillygize
397 views39 slides

Similar to Appcelerator Titanium Intro(20)

Intro to Appcelerator Titanium - Code for Fort Lauderdale 2015 by Adam Paxton
Intro to Appcelerator Titanium - Code for Fort Lauderdale 2015Intro to Appcelerator Titanium - Code for Fort Lauderdale 2015
Intro to Appcelerator Titanium - Code for Fort Lauderdale 2015
Adam Paxton1.4K views
Mobile ECM with JavaScript - JSE 2011 by Nuxeo
Mobile ECM with JavaScript - JSE 2011Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011
Nuxeo865 views
The Big Easy: Native Mobile App Development with Appcelerator Titanium and Ja... by Adam Paxton
The Big Easy: Native Mobile App Development with Appcelerator Titanium and Ja...The Big Easy: Native Mobile App Development with Appcelerator Titanium and Ja...
The Big Easy: Native Mobile App Development with Appcelerator Titanium and Ja...
Adam Paxton917 views
State ofappdevelopment by gillygize
State ofappdevelopmentState ofappdevelopment
State ofappdevelopment
gillygize397 views
Adventures in cross platform ConnectJS / TiConnect 2014 by Jason Kneen
Adventures in cross platform ConnectJS / TiConnect 2014Adventures in cross platform ConnectJS / TiConnect 2014
Adventures in cross platform ConnectJS / TiConnect 2014
Jason Kneen1K views
Getting started with titanium by Naga Harish M
Getting started with titaniumGetting started with titanium
Getting started with titanium
Naga Harish M866 views
SumitK's mobile app dev using drupal as base ststem by Sumit Kataria
SumitK's mobile app dev using drupal as base ststemSumitK's mobile app dev using drupal as base ststem
SumitK's mobile app dev using drupal as base ststem
Sumit Kataria927 views
Native Mobile Application Using Java Script by Borey Lim
Native  Mobile  Application  Using  Java ScriptNative  Mobile  Application  Using  Java Script
Native Mobile Application Using Java Script
Borey Lim1.1K views
Modeveast Appcelerator Presentation by Aaron Saunders
Modeveast Appcelerator PresentationModeveast Appcelerator Presentation
Modeveast Appcelerator Presentation
Aaron Saunders1.2K views
Build mini - Windows 10 Dev & Cross platform Dev by Ian Chen
Build mini - Windows 10 Dev & Cross platform DevBuild mini - Windows 10 Dev & Cross platform Dev
Build mini - Windows 10 Dev & Cross platform Dev
Ian Chen733 views

More from Nicholas Jansma

Modern Metrics (2022) by
Modern Metrics (2022)Modern Metrics (2022)
Modern Metrics (2022)Nicholas Jansma
15 views88 slides
Check Yourself Before You Wreck Yourself: Auditing and Improving the Performa... by
Check Yourself Before You Wreck Yourself: Auditing and Improving the Performa...Check Yourself Before You Wreck Yourself: Auditing and Improving the Performa...
Check Yourself Before You Wreck Yourself: Auditing and Improving the Performa...Nicholas Jansma
232 views41 slides
When Third Parties Stop Being Polite... and Start Getting Real by
When Third Parties Stop Being Polite... and Start Getting RealWhen Third Parties Stop Being Polite... and Start Getting Real
When Third Parties Stop Being Polite... and Start Getting RealNicholas Jansma
656 views83 slides
Reliably Measuring Responsiveness by
Reliably Measuring ResponsivenessReliably Measuring Responsiveness
Reliably Measuring ResponsivenessNicholas Jansma
3K views61 slides
Make It Fast - Using Modern Browser Performance APIs to Monitor and Improve t... by
Make It Fast - Using Modern Browser Performance APIs to Monitor and Improve t...Make It Fast - Using Modern Browser Performance APIs to Monitor and Improve t...
Make It Fast - Using Modern Browser Performance APIs to Monitor and Improve t...Nicholas Jansma
2.7K views86 slides
Debugging IE Performance Issues with xperf, ETW and NavigationTiming by
Debugging IE Performance Issues with xperf, ETW and NavigationTimingDebugging IE Performance Issues with xperf, ETW and NavigationTiming
Debugging IE Performance Issues with xperf, ETW and NavigationTimingNicholas Jansma
5.8K views20 slides

More from Nicholas Jansma(6)

Check Yourself Before You Wreck Yourself: Auditing and Improving the Performa... by Nicholas Jansma
Check Yourself Before You Wreck Yourself: Auditing and Improving the Performa...Check Yourself Before You Wreck Yourself: Auditing and Improving the Performa...
Check Yourself Before You Wreck Yourself: Auditing and Improving the Performa...
Nicholas Jansma232 views
When Third Parties Stop Being Polite... and Start Getting Real by Nicholas Jansma
When Third Parties Stop Being Polite... and Start Getting RealWhen Third Parties Stop Being Polite... and Start Getting Real
When Third Parties Stop Being Polite... and Start Getting Real
Nicholas Jansma656 views
Make It Fast - Using Modern Browser Performance APIs to Monitor and Improve t... by Nicholas Jansma
Make It Fast - Using Modern Browser Performance APIs to Monitor and Improve t...Make It Fast - Using Modern Browser Performance APIs to Monitor and Improve t...
Make It Fast - Using Modern Browser Performance APIs to Monitor and Improve t...
Nicholas Jansma2.7K views
Debugging IE Performance Issues with xperf, ETW and NavigationTiming by Nicholas Jansma
Debugging IE Performance Issues with xperf, ETW and NavigationTimingDebugging IE Performance Issues with xperf, ETW and NavigationTiming
Debugging IE Performance Issues with xperf, ETW and NavigationTiming
Nicholas Jansma5.8K views

Recently uploaded

Web Dev - 1 PPT.pdf by
Web Dev - 1 PPT.pdfWeb Dev - 1 PPT.pdf
Web Dev - 1 PPT.pdfgdsczhcet
52 views45 slides
Combining Orchestration and Choreography for a Clean Architecture by
Combining Orchestration and Choreography for a Clean ArchitectureCombining Orchestration and Choreography for a Clean Architecture
Combining Orchestration and Choreography for a Clean ArchitectureThomasHeinrichs1
68 views24 slides
Java Platform Approach 1.0 - Picnic Meetup by
Java Platform Approach 1.0 - Picnic MeetupJava Platform Approach 1.0 - Picnic Meetup
Java Platform Approach 1.0 - Picnic MeetupRick Ossendrijver
25 views39 slides
Microchip: CXL Use Cases and Enabling Ecosystem by
Microchip: CXL Use Cases and Enabling EcosystemMicrochip: CXL Use Cases and Enabling Ecosystem
Microchip: CXL Use Cases and Enabling EcosystemCXL Forum
129 views12 slides
MemVerge: Memory Viewer Software by
MemVerge: Memory Viewer SoftwareMemVerge: Memory Viewer Software
MemVerge: Memory Viewer SoftwareCXL Forum
118 views10 slides

Recently uploaded(20)

Web Dev - 1 PPT.pdf by gdsczhcet
Web Dev - 1 PPT.pdfWeb Dev - 1 PPT.pdf
Web Dev - 1 PPT.pdf
gdsczhcet52 views
Combining Orchestration and Choreography for a Clean Architecture by ThomasHeinrichs1
Combining Orchestration and Choreography for a Clean ArchitectureCombining Orchestration and Choreography for a Clean Architecture
Combining Orchestration and Choreography for a Clean Architecture
ThomasHeinrichs168 views
Microchip: CXL Use Cases and Enabling Ecosystem by CXL Forum
Microchip: CXL Use Cases and Enabling EcosystemMicrochip: CXL Use Cases and Enabling Ecosystem
Microchip: CXL Use Cases and Enabling Ecosystem
CXL Forum129 views
MemVerge: Memory Viewer Software by CXL Forum
MemVerge: Memory Viewer SoftwareMemVerge: Memory Viewer Software
MemVerge: Memory Viewer Software
CXL Forum118 views
Architecting CX Measurement Frameworks and Ensuring CX Metrics are fit for Pu... by NUS-ISS
Architecting CX Measurement Frameworks and Ensuring CX Metrics are fit for Pu...Architecting CX Measurement Frameworks and Ensuring CX Metrics are fit for Pu...
Architecting CX Measurement Frameworks and Ensuring CX Metrics are fit for Pu...
NUS-ISS32 views
"Fast Start to Building on AWS", Igor Ivaniuk by Fwdays
"Fast Start to Building on AWS", Igor Ivaniuk"Fast Start to Building on AWS", Igor Ivaniuk
"Fast Start to Building on AWS", Igor Ivaniuk
Fwdays36 views
Business Analyst Series 2023 - Week 3 Session 5 by DianaGray10
Business Analyst Series 2023 -  Week 3 Session 5Business Analyst Series 2023 -  Week 3 Session 5
Business Analyst Series 2023 - Week 3 Session 5
DianaGray10165 views
GigaIO: The March of Composability Onward to Memory with CXL by CXL Forum
GigaIO: The March of Composability Onward to Memory with CXLGigaIO: The March of Composability Onward to Memory with CXL
GigaIO: The March of Composability Onward to Memory with CXL
CXL Forum126 views
Micron CXL product and architecture update by CXL Forum
Micron CXL product and architecture updateMicron CXL product and architecture update
Micron CXL product and architecture update
CXL Forum27 views
CXL at OCP by CXL Forum
CXL at OCPCXL at OCP
CXL at OCP
CXL Forum208 views
Spesifikasi Lengkap ASUS Vivobook Go 14 by Dot Semarang
Spesifikasi Lengkap ASUS Vivobook Go 14Spesifikasi Lengkap ASUS Vivobook Go 14
Spesifikasi Lengkap ASUS Vivobook Go 14
Dot Semarang35 views
PharoJS - Zürich Smalltalk Group Meetup November 2023 by Noury Bouraqadi
PharoJS - Zürich Smalltalk Group Meetup November 2023PharoJS - Zürich Smalltalk Group Meetup November 2023
PharoJS - Zürich Smalltalk Group Meetup November 2023
Noury Bouraqadi113 views
The details of description: Techniques, tips, and tangents on alternative tex... by BookNet Canada
The details of description: Techniques, tips, and tangents on alternative tex...The details of description: Techniques, tips, and tangents on alternative tex...
The details of description: Techniques, tips, and tangents on alternative tex...
BookNet Canada110 views
Webinar : Competing for tomorrow’s leaders – How MENA insurers can win the wa... by The Digital Insurer
Webinar : Competing for tomorrow’s leaders – How MENA insurers can win the wa...Webinar : Competing for tomorrow’s leaders – How MENA insurers can win the wa...
Webinar : Competing for tomorrow’s leaders – How MENA insurers can win the wa...
[2023] Putting the R! in R&D.pdf by Eleanor McHugh
[2023] Putting the R! in R&D.pdf[2023] Putting the R! in R&D.pdf
[2023] Putting the R! in R&D.pdf
Eleanor McHugh38 views
Upskilling the Evolving Workforce with Digital Fluency for Tomorrow's Challen... by NUS-ISS
Upskilling the Evolving Workforce with Digital Fluency for Tomorrow's Challen...Upskilling the Evolving Workforce with Digital Fluency for Tomorrow's Challen...
Upskilling the Evolving Workforce with Digital Fluency for Tomorrow's Challen...
NUS-ISS23 views
Future of Learning - Khoong Chan Meng by NUS-ISS
Future of Learning - Khoong Chan MengFuture of Learning - Khoong Chan Meng
Future of Learning - Khoong Chan Meng
NUS-ISS31 views
Understanding GenAI/LLM and What is Google Offering - Felix Goh by NUS-ISS
Understanding GenAI/LLM and What is Google Offering - Felix GohUnderstanding GenAI/LLM and What is Google Offering - Felix Goh
Understanding GenAI/LLM and What is Google Offering - Felix Goh
NUS-ISS39 views

Appcelerator Titanium Intro

  • 1. Nic Jansma @NicJ //nicj.net
  • 2. Who am I? Nic Jansma Spent 6 years as a dev at Microsoft - Win 7 & IE 9/10 Perf Teams Recently founded Wolverine Digital Developing high-performance websites and apps nic@nicj.net @NicJ http://nicj.net http://github.com/nicjansma
  • 3. First Two Apps (Native Android) Minifig Collector (free) TiskTasks for Todoist ($0.99) http://minifigcollector.com http://tisktasks.com
  • 4. 3rd App • October 2011: Partnered with the author of the Unofficial LEGO Minifigure Catalog to create an interactive version of his book • Wanted to release on iOS and Android • Native? PhoneGap? Appcelerator?
  • 6. Appcelerator Titanium Mobile • Titanium is a JavaScript runtime that gives you native access to the platform’s controls • You are not building a app via html/css/js (i.e. PhoneGap) JavaScript
  • 7. How Titanium Mobile Works • You write code in JavaScript • At runtime, your application has 3 major components: o JavaScript source code (minified and inlined, but not compiled, into Java/Obj-C strings) o Titanium API implementation in the native OS o JavaScript interpreter (V8/Rhino for Android, JavaScriptCore for iOS) • The JavaScript interpreter runs your JavaScript code in an environment with proxies for the native objects (windows, controls, etc)
  • 8. Getting Titanium Mobile Step 1: Sign up for Appcelerator • https://my.appcelerator.com/auth/signup • “App EXPLORE” plan = Free: Build, test, ship, sell for free • Additional plans available (more analytics, cloud, support): http://www.appcelerator.com/plans-pricing Step 2: Download Titanium Studio • http://www.appcelerator.com/platform/titanium-studio Step 3: • Profit ???
  • 9. Titanium Studio • Eclipse-- (was Aptana Studio) • Editor • Formatting • Code-completion • Build • Debug • Release
  • 10. App File Structure • I18n - Internationalization files • modules - Third-Party (or Appcelerator) native modules • Resources o app.js – Startup file o images - Generic Images o android - Android-specific images • imageshigh / etc – Android density/screen-size dirs o iphone - iOS-specific images • @2x files o lib, ui, whatever - your source file dirs
  • 11. Hello World var win = Ti.UI.createWindow({ title: 'Hello, World!', layout: 'vertical', backgroundColor: 'white' }); var helloLabel = Ti.UI.createLabel({ text: 'Hello World', color: 'black', font: { fontSize: '20sp' }, height: '40dp', width: '250dp' }); win.add(helloLabel); var helloButton = Ti.UI.createButton({ title: 'Click me!', font: { fontSize: '20sp' }, top: '20dp', height: '40dp', width: '250dp' }); helloButton.addEventListener('click', function() { alert('you clicked me!'); }); win.add(helloButton); win.open();
  • 12. Titanium Mobile APIs • AJAX / Web services • In-App Purchases • Geolocation • Camera • Media / Photo Gallery • Accelerometer • Maps • Analytics • Social Sharing (Facebook, etc) • Extensible with your own native iOS/Android packages
  • 15. Future Platform Support • Blackberry • WinPhone7
  • 16. Pros • One codebase for two platforms o You’ll (theoretically) spend less time than writing two native apps o Maintenance on one codebase should be easier in the long run • Native interface controls o Your apps can look just like native ones • Might be able to reuse your JavaScript in other parts of your project o eg., Web front-end, Node.js backend • Platform is open-source o https://github.com/appcelerator/titanium_mobile • JavaScript is fun!
  • 17. Cons • Platform is young and still changing • Need to learn a new platform / SDK / quirks o Knowing the ins & outs of native iOS / Android will help • You’ll still have lots of if(iOS){} and if(android){} o LEGO Minifig Collector has 24 blocks of code that are Android or iOS specific • Performance isn’t 100% of a native app • SDK/API Documentation is weak (but getting better) • Q&A support forum is a mess (use SO instead)
  • 18. Unofficial LEGO Minifigure Catalog • Took ~1 month to develop • http://minifigure.org/application • Releasing content updates via IAP • Got featured in iTunes Catalogs category for a week • Looking back, Titanium was the right choice for our product’s needs
  • 19. Lessons Learned • I probably spent as much time learning Titanium and building my first app as I would have spent learning native iOS o Now I can build apps in Titanium quickly, but still need to learn native iOS o 2nd+ Titanium app will be a lot easier to build • It takes time to ramp-up on good JavaScript patterns o CommonJS modules, Crockford-isms, http://shichuan.github.com/javascript-patterns/ • I like JavaScript o Now I’m developing a game where JavaScript is the whole stack: Node.js websockets and HTTP server, frontend in HTML/CSS/JS, mobile version via Titanium • iOS simulator is a lot faster to test on. Android emulator is slow! • For community support, you’ll need to use a combination of the Appcelerator API Docs, Q&A site, videos and StackOverflow
  • 20. Lessons Learned, continued • You’ll spend time adapting when they release SDK updates o 1.7.x => 1.8.x: Took me 2 days to find and fix bugs from SDK changes • You won’t double your sales just by releasing on both platforms 4500 4000 3500 3000 2500 Units 2000 1500 1000 500 0 iOS Android
  • 22. Links Appcelerator • http://appcelerator.com • http://docs.appcelerator.com/titanium/2.1/index.html • http://developer.appcelerator.com/questions/newest • http://stackoverflow.com/questions/tagged/titanium • http://vimeo.com/appcelerator Community Projects • Joli https://github.com/xavierlacot/joli.js/