SlideShare a Scribd company logo
1 of 27
Download to read offline
Firefox OS
  Mate Nadasdi
  @matenadasdi
Gaia - Gecko - Gonk
Gaia:
User interface application written in HTML on the top of the software
stack. (mozChromeEvent and mozContentEvent)


Gecko:
Application runtime. Networking stack, graphics stack, layout engine, a JS
virtual machine, and porting layers, etc.


Gonk:
A linux kernel, hardware abstraction layer, a porting target of Gecko.
Application Sandbox
Simple web apps on your Phone!


Write your web app as you did before

Packaged Apps

Hosted Apps

App manifest file
Packaged apps


a zip containing your whole application

have access to sensitive APIs on device

The store cryptographically signs the zip
with its private key
Packaged apps - Types

•   Privileged:
     o   Approved by Firefox Marketplace
     o   App resources are signed
     o   Allowed to use sensitive Web APIs
     o   Device permissions are explicit, user can change it in any time

•   Certified:
     o   intended for critical system function
     o   Device permissions are implicit


•   Plain:
    o    Marketplace signs it without any special authentication process
    o    Cannot use sensitive Web APIs
Hosted apps

•   Just like a regular website but application manifest

    file is essential

•   App manifest needs to be on the same origin

•   Optional Appcache manifest

•   Lower Web API permissions

•   one-app-per-origin policy
App Manifest

•   JSON

•   application/x-web-app-manifest+json mime-type

•   all paths must be absolute

•   list all Web API permissions

•   Specifies a set of Web Activities that the app

    supports
Web API

•       Simple Javascript APIs
•       Lot of mobile phone features implemented
•       Simple feature detection is a good practice: if ('vibrate' in
        navigator)



               WebRT APIs          (Permissions-based APIs)



    •    Permissions needs to be listed in app manifest
    •    There are only certified app APIs: WebSMS, WebTelephony,
         Idle, etc.
Web API Security levels
•   Granted by default

    Safe web APIs that don't expose privacy sensitive data. WebGL, fullscreen, etc.

•   Granted by user

    location, camera, file system access

•   Granted when installed

    No quota for localStorage, IndexedDB, offline cache

•   Granted by authorized store

    Privacy and security sensitive APIs such as Contacts API

•   Verified by signature

    Highly privileged APIs such as radio access (dialer)
Web activities


Share, pick an image, etc.


Delegating a task to another app


Register in app manifest or dynamically
Web API examples
+

Lets rock with HTML5 & CSS3
Responsive design

•   There are lot of screen resolutions out there, and there will be more!

•   CSS3 media queries

•   device-pixel-ratio

•   Don't be shy to create a landscape layout with orientation media

    queries
Single page application

•   Based on JavaScript framework


•   Navigation should be handled with History API


•   Views will be rendered from JavaScript templates,


    or AJAX request html responses


•   Routing is handled on client side
Data handling on client side

• IndexedDB
   o   Asnyc, transactional, noSQL

   o   asks for permission over ~50MB

• Application cache: Cache / Network / fallback (~5 MB /
  origin)

• LocalStorage - Permanent ( ~5 MB / Origin )
• SessionStorage - Session only ( System memory )
• Cookies - Not modifiable (~4KB / origin)
A quick and common example
       (Basic todo application)
Quick Layout / Flow example
Performance tips
•   Use HTML comments to keep DOM node values in the memory


•   Use worker thread for background jobs


•   Feel the GPU's power, use transforms & animations


•   Use lazy load to speed up startups


•   visibilitychange event is our friend


•   The common one: Avoid unnecessary reflow / repaint


•   Do not load every script at startup


•   Every frontend performance tip could be listed here too
Debugging - Firefox Developer Tools


• Responsive design Mode


• Remote debugging


• Web inspector
Debugging - Firefox OS simulator
Share our applications with the world!




•   For hosted applications just provide an url with a valid app

    manifest

•   Packaged applications should be uploaded to the marketplace

•   To update your application just upload a new manifest, or upload

    a new zip containing the new version

•   Firefox OS phone polls for app changes once per a day
Thanks!
Special thanks to David Walsh and Christian Heilmann for the review

More Related Content

What's hot

Whitebase : Assault Carrier for Micro-Services
Whitebase : Assault Carrier for Micro-ServicesWhitebase : Assault Carrier for Micro-Services
Whitebase : Assault Carrier for Micro-ServicesJaewoo Ahn
 
Deep dive into React Portals
Deep dive into React PortalsDeep dive into React Portals
Deep dive into React PortalsSouvik Basu
 
Api gateway : To be or not to be
Api gateway : To be or not to beApi gateway : To be or not to be
Api gateway : To be or not to beJaewoo Ahn
 
Mean machine
Mean machineMean machine
Mean machineNicu Dine
 
One Hour Translation at WPTLV
One Hour Translation at WPTLVOne Hour Translation at WPTLV
One Hour Translation at WPTLVdsero
 
Build a REST API for your Mobile Apps using Node.js
Build a REST API for your Mobile Apps using Node.jsBuild a REST API for your Mobile Apps using Node.js
Build a REST API for your Mobile Apps using Node.jsStormpath
 
#SPSNYC14 translating sharepoint from beginning to ending
#SPSNYC14 translating sharepoint from beginning to ending#SPSNYC14 translating sharepoint from beginning to ending
#SPSNYC14 translating sharepoint from beginning to endingVincent Biret
 
Salesforce Lightning workshop Hartford - 12 March
Salesforce Lightning workshop Hartford - 12 MarchSalesforce Lightning workshop Hartford - 12 March
Salesforce Lightning workshop Hartford - 12 MarchJitendra Zaa
 
API managment providers from API Craft NYC Meetup in NYC
API managment providers from API Craft NYC Meetup in NYCAPI managment providers from API Craft NYC Meetup in NYC
API managment providers from API Craft NYC Meetup in NYCJason M. Sherman
 
Operational API design anti-patterns (Jason Harmon)
Operational API design anti-patterns (Jason Harmon)Operational API design anti-patterns (Jason Harmon)
Operational API design anti-patterns (Jason Harmon)Nordic APIs
 
Securing SharePoint Apps with OAuth
Securing SharePoint Apps with OAuthSecuring SharePoint Apps with OAuth
Securing SharePoint Apps with OAuthKashif Imran
 
Alfresco Day Milano 2016 - Demo Data
Alfresco Day Milano 2016 - Demo DataAlfresco Day Milano 2016 - Demo Data
Alfresco Day Milano 2016 - Demo DataAlfresco Software
 
Realtime web open house
Realtime web open houseRealtime web open house
Realtime web open houseRan Wahle
 

What's hot (19)

Whitebase : Assault Carrier for Micro-Services
Whitebase : Assault Carrier for Micro-ServicesWhitebase : Assault Carrier for Micro-Services
Whitebase : Assault Carrier for Micro-Services
 
Deep dive into React Portals
Deep dive into React PortalsDeep dive into React Portals
Deep dive into React Portals
 
Widgets neil
Widgets neilWidgets neil
Widgets neil
 
Api gateway : To be or not to be
Api gateway : To be or not to beApi gateway : To be or not to be
Api gateway : To be or not to be
 
Api Design
Api DesignApi Design
Api Design
 
Mean machine
Mean machineMean machine
Mean machine
 
One Hour Translation at WPTLV
One Hour Translation at WPTLVOne Hour Translation at WPTLV
One Hour Translation at WPTLV
 
Build a REST API for your Mobile Apps using Node.js
Build a REST API for your Mobile Apps using Node.jsBuild a REST API for your Mobile Apps using Node.js
Build a REST API for your Mobile Apps using Node.js
 
#SPSNYC14 translating sharepoint from beginning to ending
#SPSNYC14 translating sharepoint from beginning to ending#SPSNYC14 translating sharepoint from beginning to ending
#SPSNYC14 translating sharepoint from beginning to ending
 
Salesforce Lightning workshop Hartford - 12 March
Salesforce Lightning workshop Hartford - 12 MarchSalesforce Lightning workshop Hartford - 12 March
Salesforce Lightning workshop Hartford - 12 March
 
API managment providers from API Craft NYC Meetup in NYC
API managment providers from API Craft NYC Meetup in NYCAPI managment providers from API Craft NYC Meetup in NYC
API managment providers from API Craft NYC Meetup in NYC
 
Operational API design anti-patterns (Jason Harmon)
Operational API design anti-patterns (Jason Harmon)Operational API design anti-patterns (Jason Harmon)
Operational API design anti-patterns (Jason Harmon)
 
Pyramid web framework
Pyramid web frameworkPyramid web framework
Pyramid web framework
 
Securing SharePoint Apps with OAuth
Securing SharePoint Apps with OAuthSecuring SharePoint Apps with OAuth
Securing SharePoint Apps with OAuth
 
Web APIs
Web APIsWeb APIs
Web APIs
 
Alfresco Day Milano 2016 - Demo Data
Alfresco Day Milano 2016 - Demo DataAlfresco Day Milano 2016 - Demo Data
Alfresco Day Milano 2016 - Demo Data
 
SharePoint Apps 101
SharePoint Apps 101SharePoint Apps 101
SharePoint Apps 101
 
Realtime web open house
Realtime web open houseRealtime web open house
Realtime web open house
 
Api crash
Api crashApi crash
Api crash
 

Viewers also liked

Ustream vs Legacy, It's never too late to start your fight! #Jsist 2014
Ustream vs Legacy, It's never too late to start your fight! #Jsist 2014Ustream vs Legacy, It's never too late to start your fight! #Jsist 2014
Ustream vs Legacy, It's never too late to start your fight! #Jsist 2014Máté Nádasdi
 
Optimizing browser experience - App!mobile 2013 conf
Optimizing browser experience - App!mobile 2013 confOptimizing browser experience - App!mobile 2013 conf
Optimizing browser experience - App!mobile 2013 confMáté Nádasdi
 
Google Chrome DevTools: Rendering & Memory profiling on Open Academy 2013
Google Chrome DevTools: Rendering & Memory profiling on Open Academy 2013Google Chrome DevTools: Rendering & Memory profiling on Open Academy 2013
Google Chrome DevTools: Rendering & Memory profiling on Open Academy 2013Máté Nádasdi
 
Frontend automation and stability
Frontend automation and stabilityFrontend automation and stability
Frontend automation and stabilityMáté Nádasdi
 
Ustream Techtalks: Google Chrome Developer Tools
Ustream Techtalks: Google Chrome Developer ToolsUstream Techtalks: Google Chrome Developer Tools
Ustream Techtalks: Google Chrome Developer ToolsMáté Nádasdi
 
Measuring Front-End Performance - What, When and How?
Measuring Front-End Performance - What, When and How?Measuring Front-End Performance - What, When and How?
Measuring Front-End Performance - What, When and How?Gareth Hughes
 
Study: The Future of VR, AR and Self-Driving Cars
Study: The Future of VR, AR and Self-Driving CarsStudy: The Future of VR, AR and Self-Driving Cars
Study: The Future of VR, AR and Self-Driving CarsLinkedIn
 

Viewers also liked (7)

Ustream vs Legacy, It's never too late to start your fight! #Jsist 2014
Ustream vs Legacy, It's never too late to start your fight! #Jsist 2014Ustream vs Legacy, It's never too late to start your fight! #Jsist 2014
Ustream vs Legacy, It's never too late to start your fight! #Jsist 2014
 
Optimizing browser experience - App!mobile 2013 conf
Optimizing browser experience - App!mobile 2013 confOptimizing browser experience - App!mobile 2013 conf
Optimizing browser experience - App!mobile 2013 conf
 
Google Chrome DevTools: Rendering & Memory profiling on Open Academy 2013
Google Chrome DevTools: Rendering & Memory profiling on Open Academy 2013Google Chrome DevTools: Rendering & Memory profiling on Open Academy 2013
Google Chrome DevTools: Rendering & Memory profiling on Open Academy 2013
 
Frontend automation and stability
Frontend automation and stabilityFrontend automation and stability
Frontend automation and stability
 
Ustream Techtalks: Google Chrome Developer Tools
Ustream Techtalks: Google Chrome Developer ToolsUstream Techtalks: Google Chrome Developer Tools
Ustream Techtalks: Google Chrome Developer Tools
 
Measuring Front-End Performance - What, When and How?
Measuring Front-End Performance - What, When and How?Measuring Front-End Performance - What, When and How?
Measuring Front-End Performance - What, When and How?
 
Study: The Future of VR, AR and Self-Driving Cars
Study: The Future of VR, AR and Self-Driving CarsStudy: The Future of VR, AR and Self-Driving Cars
Study: The Future of VR, AR and Self-Driving Cars
 

Similar to Firefox OS Weekend

Cross platform mobile application development
Cross platform mobile application developmentCross platform mobile application development
Cross platform mobile application developmentwebprogr.com
 
[2015/2016] Apache Cordova
[2015/2016] Apache Cordova[2015/2016] Apache Cordova
[2015/2016] Apache CordovaIvano Malavolta
 
Firefox OS Apps & APIs - Dutch Mobile Conference / Serbia & Montenegro App da...
Firefox OS Apps & APIs - Dutch Mobile Conference / Serbia & Montenegro App da...Firefox OS Apps & APIs - Dutch Mobile Conference / Serbia & Montenegro App da...
Firefox OS Apps & APIs - Dutch Mobile Conference / Serbia & Montenegro App da...Jan Jongboom
 
Developing Windows Phone 8 apps using PhoneGap
Developing Windows Phone 8 apps using PhoneGapDeveloping Windows Phone 8 apps using PhoneGap
Developing Windows Phone 8 apps using PhoneGapAmar Mesic
 
Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and Ryan Cuprak
 
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)Ryan Cuprak
 
Sahi Principles and Architecture
Sahi Principles and ArchitectureSahi Principles and Architecture
Sahi Principles and ArchitectureTyto Software
 
Hybrid application development
Hybrid application developmentHybrid application development
Hybrid application developmentEngin Hatay
 
HTML5 Programming
HTML5 ProgrammingHTML5 Programming
HTML5 Programminghotrannam
 
Apache Cordova phonegap plugins for mobile app development
Apache Cordova phonegap plugins for mobile app developmentApache Cordova phonegap plugins for mobile app development
Apache Cordova phonegap plugins for mobile app developmentwebprogr.com
 
Mobile application development; Complete steps
Mobile application development; Complete stepsMobile application development; Complete steps
Mobile application development; Complete steps Abin Baby
 
Decoupled Architecture and WordPress
Decoupled Architecture and WordPressDecoupled Architecture and WordPress
Decoupled Architecture and WordPressPantheon
 
Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011Nuxeo
 

Similar to Firefox OS Weekend (20)

Webapi
WebapiWebapi
Webapi
 
Rhodes
RhodesRhodes
Rhodes
 
Apache Cordova 4.x
Apache Cordova 4.xApache Cordova 4.x
Apache Cordova 4.x
 
Cross platform mobile application development
Cross platform mobile application developmentCross platform mobile application development
Cross platform mobile application development
 
[2015/2016] Apache Cordova
[2015/2016] Apache Cordova[2015/2016] Apache Cordova
[2015/2016] Apache Cordova
 
20120802 timisoara
20120802 timisoara20120802 timisoara
20120802 timisoara
 
Firefox OS Apps & APIs - Dutch Mobile Conference / Serbia & Montenegro App da...
Firefox OS Apps & APIs - Dutch Mobile Conference / Serbia & Montenegro App da...Firefox OS Apps & APIs - Dutch Mobile Conference / Serbia & Montenegro App da...
Firefox OS Apps & APIs - Dutch Mobile Conference / Serbia & Montenegro App da...
 
Developing Windows Phone 8 apps using PhoneGap
Developing Windows Phone 8 apps using PhoneGapDeveloping Windows Phone 8 apps using PhoneGap
Developing Windows Phone 8 apps using PhoneGap
 
Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and Hybrid Mobile Development with Apache Cordova and
Hybrid Mobile Development with Apache Cordova and
 
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
Hybrid Mobile Development with Apache Cordova and Java EE 7 (JavaOne 2014)
 
Sahi Principles and Architecture
Sahi Principles and ArchitectureSahi Principles and Architecture
Sahi Principles and Architecture
 
20120306 dublin js
20120306 dublin js20120306 dublin js
20120306 dublin js
 
Hybrid application development
Hybrid application developmentHybrid application development
Hybrid application development
 
HTML5 Programming
HTML5 ProgrammingHTML5 Programming
HTML5 Programming
 
Apache Cordova
Apache CordovaApache Cordova
Apache Cordova
 
Apache Cordova phonegap plugins for mobile app development
Apache Cordova phonegap plugins for mobile app developmentApache Cordova phonegap plugins for mobile app development
Apache Cordova phonegap plugins for mobile app development
 
Mobile application development; Complete steps
Mobile application development; Complete stepsMobile application development; Complete steps
Mobile application development; Complete steps
 
Decoupled Architecture and WordPress
Decoupled Architecture and WordPressDecoupled Architecture and WordPress
Decoupled Architecture and WordPress
 
Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011Mobile ECM with JavaScript - JSE 2011
Mobile ECM with JavaScript - JSE 2011
 
Mobile app development
Mobile app development  Mobile app development
Mobile app development
 

Recently uploaded

Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 

Recently uploaded (20)

Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 

Firefox OS Weekend

  • 1. Firefox OS Mate Nadasdi @matenadasdi
  • 2. Gaia - Gecko - Gonk Gaia: User interface application written in HTML on the top of the software stack. (mozChromeEvent and mozContentEvent) Gecko: Application runtime. Networking stack, graphics stack, layout engine, a JS virtual machine, and porting layers, etc. Gonk: A linux kernel, hardware abstraction layer, a porting target of Gecko.
  • 3.
  • 5. Simple web apps on your Phone! Write your web app as you did before Packaged Apps Hosted Apps App manifest file
  • 6. Packaged apps a zip containing your whole application have access to sensitive APIs on device The store cryptographically signs the zip with its private key
  • 7. Packaged apps - Types • Privileged: o Approved by Firefox Marketplace o App resources are signed o Allowed to use sensitive Web APIs o Device permissions are explicit, user can change it in any time • Certified: o intended for critical system function o Device permissions are implicit • Plain: o Marketplace signs it without any special authentication process o Cannot use sensitive Web APIs
  • 8. Hosted apps • Just like a regular website but application manifest file is essential • App manifest needs to be on the same origin • Optional Appcache manifest • Lower Web API permissions • one-app-per-origin policy
  • 9. App Manifest • JSON • application/x-web-app-manifest+json mime-type • all paths must be absolute • list all Web API permissions • Specifies a set of Web Activities that the app supports
  • 10.
  • 11. Web API • Simple Javascript APIs • Lot of mobile phone features implemented • Simple feature detection is a good practice: if ('vibrate' in navigator) WebRT APIs (Permissions-based APIs) • Permissions needs to be listed in app manifest • There are only certified app APIs: WebSMS, WebTelephony, Idle, etc.
  • 12. Web API Security levels • Granted by default Safe web APIs that don't expose privacy sensitive data. WebGL, fullscreen, etc. • Granted by user location, camera, file system access • Granted when installed No quota for localStorage, IndexedDB, offline cache • Granted by authorized store Privacy and security sensitive APIs such as Contacts API • Verified by signature Highly privileged APIs such as radio access (dialer)
  • 13. Web activities Share, pick an image, etc. Delegating a task to another app Register in app manifest or dynamically
  • 15. + Lets rock with HTML5 & CSS3
  • 16. Responsive design • There are lot of screen resolutions out there, and there will be more! • CSS3 media queries • device-pixel-ratio • Don't be shy to create a landscape layout with orientation media queries
  • 17. Single page application • Based on JavaScript framework • Navigation should be handled with History API • Views will be rendered from JavaScript templates, or AJAX request html responses • Routing is handled on client side
  • 18. Data handling on client side • IndexedDB o Asnyc, transactional, noSQL o asks for permission over ~50MB • Application cache: Cache / Network / fallback (~5 MB / origin) • LocalStorage - Permanent ( ~5 MB / Origin ) • SessionStorage - Session only ( System memory ) • Cookies - Not modifiable (~4KB / origin)
  • 19. A quick and common example (Basic todo application)
  • 20. Quick Layout / Flow example
  • 21. Performance tips • Use HTML comments to keep DOM node values in the memory • Use worker thread for background jobs • Feel the GPU's power, use transforms & animations • Use lazy load to speed up startups • visibilitychange event is our friend • The common one: Avoid unnecessary reflow / repaint • Do not load every script at startup • Every frontend performance tip could be listed here too
  • 22.
  • 23.
  • 24. Debugging - Firefox Developer Tools • Responsive design Mode • Remote debugging • Web inspector
  • 25. Debugging - Firefox OS simulator
  • 26. Share our applications with the world! • For hosted applications just provide an url with a valid app manifest • Packaged applications should be uploaded to the marketplace • To update your application just upload a new manifest, or upload a new zip containing the new version • Firefox OS phone polls for app changes once per a day
  • 27. Thanks! Special thanks to David Walsh and Christian Heilmann for the review