SlideShare ist ein Scribd-Unternehmen logo
1 von 115
Downloaden Sie, um offline zu lesen
Gran Sasso Science Institute | University of L’Aquila
Ivano Malavolta
HTML5: the new frontier of the web
About me…
Ivano Malavolta

Post Doc researcher – Gran Sasso Science Institute
www.ivanomalavolta.com
Roadmap
Anatomy of a web app
Debugging (mobile) web apps
HTML5
Maintainable web apps
Roadmap
Anatomy of a web app
What is a Web App?
An application built with web technologies that is accessible via a mobile browser and 
NOT EXCLUSIVELY through an app store

The browser may be either 
the standard device browser 
or an embedded browser 
(Hybrid app)
Anatomy of a Web App
Setting up the Server



As usual, it all starts with an HTTP request
Then you need:
•  Data
•  A device detection mechanism [optional]
•  The app itself
Data 
Usually mobile apps do not talk directly with the database

à do not even think about JDBC, drivers, etc!
à  They pass through an application server and communicate via:
•  standard HTTP requests for HTML content (eg PHP)
•  REST-full services (XML, JSON, etc.)
•  SOAP
Data
•  Data can be stored in any classical way:
•  Relational
•  Graph
•  Key-value
•  Document-based

Latest trend à backend-as-a-service
BaaS
1.  Developers build a visual model of their DB

2.  The service generates APIs and client-side
libraries(compatible with Android, Windows
Phone, etc.)
3.  The data produced/consumed in the app can be
pushed/pulled to their DB
•  Communication is handled via REST-based
APIs
Example of Baas software: BaasBox
Main features:
•  User management 
•  ACL
•  Friendships
•  Authentication via Facebook and Google+
•  Document-based data manegement (via OrientDB)
•  Assets management (fotos, documents, or files)
•  Push notifications
The “Box” in BaasBox means that all the features are
in a standalone server, just like a box. 

No Application Server, no Database Server, just a
JVM and nothing more
Rest API
Web
dashboard
http://www.baasbox.com/
Ok, but what about mobile apps?
BROWSER


<html>
<head>
<script src=” ...” />
</head>
<body>
...
NATIVE
WRAPPER

<html>
<head>
<script src=” ...” />
</head>
<body>
...
PLATFORM APIs	

NATIVE 
APP

01010101010101101010
1010101011011010
010101010101011101
010101010101011010




PLATFORM APIs	

Native
 Web
 Hybrid
Native
http://bit.ly/GWOaP1
PRO
•  Lets you create apps with rich user interfaces and/or heavy graphics

CONS
•  Development Time
•  Development Cost
•  Ongoing Maintenance
•  No portability (apps cannot be used on other platforms)
PRO
CONS
Examples of native apps
http://www.ea.com/it/ipad/nfs 
http://www.whatsapp.com/
Web
http://bit.ly/GWOaP1
PRO
•  Offers fast development, simple maintenance, and full application portability
•  One mobile web app works on any platform

CONS
•  Can’t handle heavy graphics
•  Can’t access camera or microphone
PRO
CONS
Examples of web apps
http://asidemag.com
http://amazon.com
Hybrid
http://bit.ly/GWOaP1
PRO
•  Development speed of mobile web apps 
•  Device access and app store distribution of native apps

CONS
•  Can’t handle heavy graphics
•  Requires familiarity with a mobile framework
PRO
CONS
Examples of hybrid apps
http://www.gmail.com
http://flipboard.com
Frascati Scienza
QR code scanning	

In-app RSS feed reader	

Maps	

Non-linear layouts	

https://itunes.apple.com/it/app/frascati-scienza-scienziati/id686974321?mt=8
Comparison
My vision
Mobile web seems to be the only long-term commercially viable platform for mobile

FRAGMENTATION
THE WEB
USER EXPECTATIONS
When you go native there are too many platforms to be supported


FRAGMENTATION
The web is the only platform that:
•  works across devices
•  apps share the same set of standards
•  the same app can work also on a desktop
THE WEB
The web is an advanced technology:
•  webGL
•  Local storage management
•  Positioning & mapping
•  Real-time data
•  Push, ...
Users expect things to just work

à they don’t care about what platform they have
àthey simply expect that your app will be available for their device 




à YOU HAVE TO BE CROSS-PLATFORM
USER EXPECTATIONS
PhoneGap
You develop your app using the usual three guys




You use the same web view of the native OS
•  iOS = UIWebView
•  Android = android.webkit.WebView

http://phonegap.com/blog/2013/06/20/coming-soon-phonegap30
What is PhoneGap?
The UI layer is a web browser view
•  100% width
•  100% height

Headless web browser
•  No URL bar
•  No decorations
•  No zooming
•  No text selection
It looks very similar to Apache Cordova…
Adobe/Nitobi donated the PhoneGap codebase to the Apache foundation
à 
wider audience and contributors
à 
transparent governance


Better documentation
à 
easier contributions for companies


Apache Licensing
There was only one problem....


trademark ambiguity 

à CORDOVA
PhoneGap is a distribution of
Apache Cordova
Roadmap
Anatomy of a web app
 HTML5
HTML 5
HTML5 will be the new standard for HTML

HTML5 is still a work in progress

W3C final recomendation: 2020

Top browsers support many (not all) of the new HTML5 elements
http://mobilehtml5.org
http://caniuse.com
What is HTML5?
It is an extension of HTML/XHTML 4

•  with new more semantically rich elements
<article>, <footer>, <header>, <nav>, <section>
•  deprecating tags & attributes
<center>, <font>, <frame>, height, width
•  introducing new attributes
placeholder, form
•  additional APIs
geolocalization, video, audio
HTML5
Markup
 JavaScript
CSS3
Multimedia
The minimal HTML5 page
<!DOCTYPE	
  html>	
  
<html>	
  
	
  <head>	
  
	
  <title>Title</title>	
  
</head>	
  
	
  <body>	
  
…	
  
</body>	
  
</html>	
  
New Structural Tags
Main Goal: separate presentation from content

•  Poor accessibility
•  Unnecessary complexity
•  Larger document size

Most of the presentational features from earlier versions of HTML are no longer supported
New structural tags
New Structural Tags
<header> header region of a page or section
<footer> footer region of a page or section
<nav> navigation region of a page or section
<section> logical region of a page
<article> a complete piece of content
<aside> secondary or related content
http://bit.ly/JCnuQJ
Custom Data Attributes
Can be used to add metadata about any element within an HTML5 page

They are ignored by the validator for HTML5 documents

They all start with the data- pattern

They can be read by any browser using Javascript via the getAttribute() method

These attributes are used by
many JavaScript frameworks
Forms
Main Goal: reduce the Javascript for validation and format management






 


 


 Example:
Forms
Form Input Types
Form input types degrade gracefully
à 
Unknown input types are treated as text-type
http://bit.ly/I65jai
Audio
<audio> : a standard way to embed an audio file on a web page

<audio controls>
<source src="song.ogg" type="audio/ogg" />
<source src="song.mp3" type="audio/mpeg" />
Not Supported
</audio>
Multiple sources à the browser will use the first recognized format
Audio
Audio Javascript API
HTML5 provides a set of Javascript APIs for interacting with an audio element


For example:

play() pause() load() currentTime ended volume…


à http://www.w3.org/wiki/HTML/Elements/audio
Video
<video> : a standard way to embed a video file on a web page

<video width="320" height="240" controls>
<source src="movie.mp4" type="video/mp4" />
<source src="movie.ogg" type="video/ogg" />
Not Supported
</video>
Multiple sources à the browser will use the first recognized format
Video
Video Javascript API
HTML5 provides a set of Javascript APIs for interacting with a video element


For example:

play() pause() load() currentTime ended volume…


à http://www.w3.org/wiki/HTML/Elements/video
Accelerometer

There are 4 ways to store data locally in Cordova:
•  Web storage
•  Local Storage
•  Session Storage
•  WebSQL
•  Indexed DB
•  File System Access
Local storage and file system access
Web storage, WebSQL, and IndexedDB 
conform to W3C specifications and are
provided by the browser itself
File system access API conforms to its
corresponding W3C specification
Web Storage

LocalStorage

stores data in key/value pairs

persists across browser sessions

SessionStorage

stores data in key/value pairs

data is erased when a browser session ends
WebSQL


relational DB

support for tables creation, insert, update, …

transactional

persists across browser sessions

Its evolution is called IndexedDB
WebSQL
It provides you a structured SQL relational database

You have to setup a DB schema

You can then perform classical SQL queries

tx.executeSql("SELECT	
  *	
  FROM	
  User“,	
  [],	
  
	
  function(tx,	
  result)	
  {	
  
	
   	
  //	
  callback	
  code	
  
});	
  
IndexedDB
•  It tries to combine Web Storage and WebSQL
•  You can save data as key/value pairs
•  You can define multiple DBs
•  Good Performance


data is indexed


asynchronous ! it does not block the UI

You can see a store as a big SQL table with only key/value pairs


à you don’t need to define a schema upfront
Considerations
You will likely use more than one API in combination
à Use the right API for the right job

Local Storage
•  it is not transactional à race conditions
•  very simple API, no schema 
•  only String data à performance issues for complex data due to JSON serialization
•  session storage will be cleared after the app is closed
•  limited quota
Considerations

WebSQL
•  SQL-based à fast and efficient
•  transactional à more robust
•  asynchronous à does not block the UI
•  rigid data structure à data integrity vs agility
•  limited quota
Considerations
IndexedDB
•  simple data model à easy to use
•  transactional à more robust
•  asynchronous à does not block the UI
•  good search performance à indexed data
•  data is unstructured à integrity problems
•  limited quota
•  not supported by every platform (e.g., iOS)
Platforms support
Geolocalization

Gets Latitude and Longitude from the user’s browser


There is also a watchPosition method wich calls a JS function every time the user moves


Geolocalization
Example
function getLocation() {
if(navigator.geolocation) {
navigator.geolocation.getCurrentPosition(showPosition);
} else {
console.log(‘no geolocalization’);
}
}
function showPosition(position) {
console.log(position.coords.latitude);
console.log(position.coords.longitude);
}
WebSockets

Bidirectional, full-duplex communication between devices and server

Specifically suited for

chat, videogames, drawings sharing, real-time info

Requires a Web Socket Server to handle the protocol

Web sockets
WebSockets - Overview
1.  Client notifies websocket server (EventMachine) of an event, giving ids of recipients
2.  The server notifies all the active clients (subscribed to that type of event)
3.  Clients process event 

when given recipient Id 

matches the client’s one
http://bit.ly/Ixcupi
Alternative - Polling via AJAX
+ Near real-time updates (not purely real-time)
+ easy to implement
+ no new technologies needed

-  they are requested from the client and cause increased network traffic
-  AJAX requests generally have a small payload and relatively high amount of http headers
(wasted bandwith)
Canvas
Canvas allows you to draw anything inside the browser
http://bit.ly/Ie4HKu
http://bit.ly/LUKXkr
http://bit.ly/LULa79
http://bit.ly/LC8AgY
Canvas
Canvas
It uses nothing more than JavaScript and HTML 

à no external plugins, no libraries, etc.

You can create lines, use images, use text, apply transformations, etc.
http://bit.ly/KsKLv1
Canvas example: the Impavida project
http://www.impavida.com/
placeholder
Web Workers
Javascript is a single-threaded language
à If a tasks take a lot of time, users have to wait


Web Workers provide background processing capabilities to web applications

They typically run on separate threads 

à apps can take advantage of multicore CPUs
Web workers
Web Workers
Web Workers can be used to:
•  prefetch data from the Web
•  perform other ahead-of-time operations to provide a much more lively UI.

Precious on mobile Web applications because of the slow network speed
Web Workers
Any JS file can be launched as a worker

Example of Web Worker declaration:

var worker = new Worker(“worker.js”);
In order to be independent from other workers, each worker script cannot access the DOM
Web Workers
The main JS script can communicate with workers via postMessage() calls:


$(‘#button’).click(function(event) {
$(‘#output’).html(“starting”);
worker.postMessage(“start”);
});
worker.onmessage = function(event) {
$(‘#output’).html(event.data);
}
Web Workers
The web worker script can post back messages to the main script:


onmessage = function(event) {
if(event.data === “start”) {
var result;
// do something with result
postMessage(result);
}
}
Roadmap
Anatomy of a web app
Debugging (mobile) web apps
HTML5
The killer app!
•  Check console
•  Breakpoints
•  Update the DOM at run-time
•  Access to all local DBs
•  Network profiling
•  CPU and memory profiling
•  Monitor event listeners
•  Monitor elements’ rendering time
Desktop Browser
•  very quick
•  very handy functions
•  see Chrome’s Web Development Tools
•  Breakpoints


PRO
•  browsers’ small differences and bugs
•  cannot test all mobile-specific functionalities
•  you need PhoneGap shims 

CONS
Desktop Browser
Ripple
•  very quick
•  can use Chrome’s Web Development Tools
•  You can test PhoneGap’s API from the Desktop
•  browsers’ small differences and bugs
•  cannot test the interaction with external apps
PRO
CONS
It is based on Ripple, a Chrome
plugin for mobile dev 



from PhoneGap 3.0.0, you need to
use the Ripple available at Apache 
npm	
  install	
  -­‐g	
  ripple-­‐emulator	
  
ripple	
  emulate	
  
Apache Ripple
Simulator
•  Officially supported by platform vendors 

•  You use the “real” device’s browser
PRO
•  device’s performance is not considered 
•  this is iOS-specific
•  Android’s emulator is a joke
•  device’s capabilities are only simulated
CONS
On device
•  accurate
•  still handy
•  real performance tests
•  real browser tests
PRO
•  Deployment takes some time (~6 seconds for iOS)
CONS
Remote Debugging
From iOS 6, Apple provided Mobile Safari with a remote web inspector
à You can debug your app by using the classical web inspector of Desktop Safari

It can connect both to
•  The iOS emulator
•  The real device

Since Android 4.4, this feature is
available via Chrome’s web dev kit
Mobile debugging reference table 
Make a favor to yourself, 
don’t debug craftsman way:

console.log()	
  +	
  alert()	
  

iOS
 Android
Desktop Browser
 
 
Ripple
 
 
Device/emulator
 
 
Safari Web
Inspector

 X
Chrome Web
Inspector
X
Roadmap
Anatomy of a web app
Debugging (mobile) web apps
HTML5
Maintainable web apps
Roadmap
•  Introduction
•  Backbone 
•  Require JS
•  Handlebars
•  Combining backbone, Require, and Handlebars
Introduction
We are building apps, not web sites

If your code is not structured:
•  it is extremely easy that your web app becomes a 

 
big mess of HTML + CSS + JavaScript
•  maintaining each part of your app asks for a 

 
deep analysis of ALL its aspects (logic, presentation, etc.)
•  you may waste a whole day due to a missing 	
  <	
  
What we want to avoid





Imagine yourself trying to change either: 
•  how a movie should be rendered in your app
•  the REST API providing info about movies
Roadmap
•  Introduction
•  Backbone 
•  Require JS
•  Handlebars
•  Combining backbone, Require, and Handlebars
Why Backbone

Backbone gives you
 STRUCTURE
Why Backbone

From the Backbone website...
manipulate 
the DOM
lists 
of models
represent 
data
Who is using Backbone?
Backbone events


Basically, each object can:
•  listen to events
•  trigger events
Models

Models represent your data

Each model represents a data type in your app, together with the logic surrounding it, like:
•  persistence
•  conversions
•  validation
•  computed properties
•  access control
MVC: Notify their observers about their
state using the Observer pattern
Example of model
http://goo.gl/UOahsP
custom method
setting an 
attribute
custom method
invocation
constructor
default attributes
getting an 
attribute
Models API overview
Collections
Collections are ordered sets of models

You can: 
•  bind change events to be notified when any model in the collection has been modified
•  listen for add and remove events
•  fetch the collection from the server (or other persistence layers)
•  find models or filter collections themeselves

The model attribute of a collection represents the kind of model that can be stored in it
Any event that is triggered on a model in a collection
will also be triggered on the collection directly
MVC: Notify their observers
about state using the Observer
pattern (same as models)
Example of collection
http://goo.gl/UOahsP
type of stored
models
Instance of
collection
Collections API overview
Views
Views represent and manage the visible parts of your application

They are also used to 
•  listen to interaction events 
•  and react accordingly

views can be rendered at any time, and inserted into the DOM

 you get high-performance UI rendering 
with as few reflows and repaints as possible
MVC: observe models, and
update itself according to the
state of the models + manage
user inputs (it’s a controller, to
this sense)
Example of view
Events map
“event_name selector”: callback
Events callbacks
create the
DOM subtree
Views API overview
The router
Backbone.Router	
  provides methods for routing client-side pages, 
and connecting them to actions and events

At a minimum, a router is composed of two main parts:
routes


an hash that pairs routes to actions 
actions


JS functions triggered when certain routes are navigated
Example of router
routes map
routing
functions
Backbone-based workflow
•  You organize your interface into logical views backed by models
•  Each view can be updated independently when the model changes,
without having to redraw the page
You can bind your view‘s
render() function to the
model‘s "change” event 

à 
now everywhere that
model data is displayed in the
UI, it is always up to date
Roadmap
•  Introduction
•  Backbone 
•  Require JS
•  Handlebars
•  Combining backbone, Require, and Handlebars
Why Require JS

We are building apps, not website

We need well-specified and isolated JS files/modules

Code complexity grows as the app gets bigger




 
à we need some sort of #include/import/require	
  


à ability to load nested dependencies
What we want to avoid












 




 
 
 
 
 
uncontrolled scripts
poor control flow understanding
Require JS
RequireJS is a JavaScript file and module loader
Using a modular script loader like Require JS will improve the modularity of your code:
à  speed in implementing changes
à  better undestanding of the code

Require JS allows modules to be loaded as fast as possible, even out of order, but evaluated in the
correct dependency order
It is built on the Module Pattern
JavaScript file and module loader
Module example

Technically, it is simply a function that executes immediately
Module VS script files






A module is different from a traditional script file in that it defines a well-scoped object that avoids
polluting the global namespace à its retained objects can be deleted by the GC
It can explicitly list its dependencies and get a handle on those dependencies without needing to refer to
global objects, but instead receive the dependencies as arguments to the function that defines the
module
VS
Module definition
Required
modules (array)
References to required modules
Dependent module usage
This function is called when
zepto.js is loaded. 
If zepto.js calls define(), then
this function is not fired until
also zepto’s dependencies
have loaded
Require JS under the hoods...
1.  loads each dependency as a script tag, using head.appendChild() and waits for all dependencies to
load
2.  computes the right order in which to call the functions that define the modules
3.  calls the module definition functions of each dependency in the right order
main.js
jQuery
 Backbone
SpinJS
MoviesCollection
MovieModel
MoviesView
1
2
3
 4
5
6
7
Roadmap
•  Introduction
•  Backbone 
•  Require JS
•  Handlebars
•  Combining backbone, Require, and Handlebars
Why Handlebars
We want to separate presentation from logic
TRANSLATE TO: we don’t want to put any HTML element into JavaScript code
separate logic from presentation
Imagine yourself trying to change how a movie should be rendered in
your app...
Handlebars template
A handlebars expression is 

{{ something  }}
Template compilation
	
  
Handlebars.compile is used to compile a template




Compiling = obtaining a JS object representing the template
Templates population
You have to execute a template with a context
in order to get its corresponding HTML code
handlebars summary
Each Template can contain Expressions and Helpers operating on them

The main helpers are: 
•  with	
  
•  each	
  
•  if	
  /	
  else	
  /unless	
  


You can define your own Helpers that operate on expressions, they return HTML code


A template can be (pre)-compiled and must be executed with a context in order to return the
final HTML fragment
Example of built-in helper


It renders the block if its argument is not equal to false,	
  undefined,	
  null,	
  []	
  
If / Else
<div	
  class="entry“>	
  
<h1>{{title}}</h1>	
  
{{#if	
  author}}	
  
	
  <h2>By	
  {{firstName}}	
  {{lastName}}</h2>	
  
{{#else}}	
  
	
  <h2>Unknown	
  author</h1>	
  	
  
{{/if}}	
  
{	
  title:	
  "My	
  first	
  post!",	
  	
  
	
  	
  	
  author:	
  undefined	
  }	
  
}	
  	
  
<div	
  class="entry“>	
  
<h1>My	
  first	
  post!</h1>	
  
<h2>Unknown	
  author</h2>	
  
</div>	
  	
  
Roadmap
•  Introduction
•  Backbone 
•  Require JS
•  Handlebars
•  Combining backbone, Require, and Handlebars
Combining Backbone, Require, and Handlebars
Handlebars templates can be seen as special Require modules

So we can have the following:

•  a separate HTML5 file for each template 
•  a Backbone view can have a dependency to each template
•  the template can be executed by using a JSON object of the Backbone model as context
Example
Dependency to template HTML file
It contains a string 
Compiled template
Execution of the template
How I structure my mobile apps
I implemented all best practices and advices in this
presentation in a generic app template available here:

https://github.com/iivanoo/cordovaboilerplate
References
http://backbonejs.org
http://requirejs.org
http://handlebarsjs.com
https://github.com/iivanoo/cordovaboilerplate
+ 39 380 70 21 600
Contact
Ivano Malavolta |
Gran Sasso Science Institute
iivanoo
ivano.malavolta@univaq.it
www.ivanomalavolta.com

Weitere ähnliche Inhalte

Was ist angesagt?

SPTechCon 2014 How to develop and debug client side code in SharePoint
SPTechCon 2014 How to develop and debug client side code in SharePointSPTechCon 2014 How to develop and debug client side code in SharePoint
SPTechCon 2014 How to develop and debug client side code in SharePointMark Rackley
 
HTML5 Offline Web Application
HTML5 Offline Web ApplicationHTML5 Offline Web Application
HTML5 Offline Web ApplicationAllan Huang
 
Introduction to Client Side Dev in SharePoint Workshop
Introduction to Client Side Dev in SharePoint WorkshopIntroduction to Client Side Dev in SharePoint Workshop
Introduction to Client Side Dev in SharePoint WorkshopMark Rackley
 
Html5 Offline Applications
Html5 Offline Applications Html5 Offline Applications
Html5 Offline Applications Sunny Sharma
 
Fundamentals of web_design_v2
Fundamentals of web_design_v2Fundamentals of web_design_v2
Fundamentals of web_design_v2hussain534
 
High performance website
High performance websiteHigh performance website
High performance websiteChamnap Chhorn
 
DevNext - Web Programming Concepts Using Asp Net
DevNext - Web Programming Concepts Using Asp NetDevNext - Web Programming Concepts Using Asp Net
DevNext - Web Programming Concepts Using Asp NetAdil Mughal
 
Bringing HTML5 alive in SharePoint
Bringing HTML5 alive in SharePointBringing HTML5 alive in SharePoint
Bringing HTML5 alive in SharePointChad Schroeder
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NETPeter Gfader
 
HTML5 Introduction
HTML5 IntroductionHTML5 Introduction
HTML5 Introductiondynamis
 
Codemotion 2013 - Designing complex applications using html5 and knockoutjs
Codemotion 2013 - Designing complex applications using html5 and knockoutjsCodemotion 2013 - Designing complex applications using html5 and knockoutjs
Codemotion 2013 - Designing complex applications using html5 and knockoutjsFabio Franzini
 
MWLUG - Universal Java
MWLUG  -  Universal JavaMWLUG  -  Universal Java
MWLUG - Universal JavaPhilippe Riand
 
HTML5 Mullet: Forms & Input Validation
HTML5 Mullet: Forms & Input ValidationHTML5 Mullet: Forms & Input Validation
HTML5 Mullet: Forms & Input ValidationTodd Anglin
 
SharePoint Saturday St. Louis - SharePoint & jQuery
SharePoint Saturday St. Louis - SharePoint & jQuerySharePoint Saturday St. Louis - SharePoint & jQuery
SharePoint Saturday St. Louis - SharePoint & jQueryMark Rackley
 
SPSDenver - SharePoint & jQuery - What I wish I would have known
SPSDenver - SharePoint & jQuery - What I wish I would have knownSPSDenver - SharePoint & jQuery - What I wish I would have known
SPSDenver - SharePoint & jQuery - What I wish I would have knownMark Rackley
 
Modern Web Development
Modern Web DevelopmentModern Web Development
Modern Web DevelopmentRobert Nyman
 

Was ist angesagt? (20)

Apache Cordova 4.x
Apache Cordova 4.xApache Cordova 4.x
Apache Cordova 4.x
 
SPTechCon 2014 How to develop and debug client side code in SharePoint
SPTechCon 2014 How to develop and debug client side code in SharePointSPTechCon 2014 How to develop and debug client side code in SharePoint
SPTechCon 2014 How to develop and debug client side code in SharePoint
 
HTML5 Offline Web Application
HTML5 Offline Web ApplicationHTML5 Offline Web Application
HTML5 Offline Web Application
 
Introduction to Client Side Dev in SharePoint Workshop
Introduction to Client Side Dev in SharePoint WorkshopIntroduction to Client Side Dev in SharePoint Workshop
Introduction to Client Side Dev in SharePoint Workshop
 
Html5 Offline Applications
Html5 Offline Applications Html5 Offline Applications
Html5 Offline Applications
 
Fundamentals of web_design_v2
Fundamentals of web_design_v2Fundamentals of web_design_v2
Fundamentals of web_design_v2
 
High performance website
High performance websiteHigh performance website
High performance website
 
Tutorial asp.net
Tutorial  asp.netTutorial  asp.net
Tutorial asp.net
 
DevNext - Web Programming Concepts Using Asp Net
DevNext - Web Programming Concepts Using Asp NetDevNext - Web Programming Concepts Using Asp Net
DevNext - Web Programming Concepts Using Asp Net
 
Bringing HTML5 alive in SharePoint
Bringing HTML5 alive in SharePointBringing HTML5 alive in SharePoint
Bringing HTML5 alive in SharePoint
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
 
HTML5 Introduction
HTML5 IntroductionHTML5 Introduction
HTML5 Introduction
 
ASP.NET Lecture 1
ASP.NET Lecture 1ASP.NET Lecture 1
ASP.NET Lecture 1
 
Top 10 web application development frameworks 2016
Top 10 web application development frameworks 2016Top 10 web application development frameworks 2016
Top 10 web application development frameworks 2016
 
Codemotion 2013 - Designing complex applications using html5 and knockoutjs
Codemotion 2013 - Designing complex applications using html5 and knockoutjsCodemotion 2013 - Designing complex applications using html5 and knockoutjs
Codemotion 2013 - Designing complex applications using html5 and knockoutjs
 
MWLUG - Universal Java
MWLUG  -  Universal JavaMWLUG  -  Universal Java
MWLUG - Universal Java
 
HTML5 Mullet: Forms & Input Validation
HTML5 Mullet: Forms & Input ValidationHTML5 Mullet: Forms & Input Validation
HTML5 Mullet: Forms & Input Validation
 
SharePoint Saturday St. Louis - SharePoint & jQuery
SharePoint Saturday St. Louis - SharePoint & jQuerySharePoint Saturday St. Louis - SharePoint & jQuery
SharePoint Saturday St. Louis - SharePoint & jQuery
 
SPSDenver - SharePoint & jQuery - What I wish I would have known
SPSDenver - SharePoint & jQuery - What I wish I would have knownSPSDenver - SharePoint & jQuery - What I wish I would have known
SPSDenver - SharePoint & jQuery - What I wish I would have known
 
Modern Web Development
Modern Web DevelopmentModern Web Development
Modern Web Development
 

Andere mochten auch

Tips for creating a Self Organizing Teams
Tips for creating a Self Organizing TeamsTips for creating a Self Organizing Teams
Tips for creating a Self Organizing TeamsYves Hanoulle
 
Learn Dashing Widget in 90 minutes
Learn Dashing Widget in 90 minutesLearn Dashing Widget in 90 minutes
Learn Dashing Widget in 90 minutesLarry Cai
 
WSO2 para o Governo Brasileiro
WSO2 para o  Governo BrasileiroWSO2 para o  Governo Brasileiro
WSO2 para o Governo BrasileiroEdgar Silva
 
Comparing JVM Web Frameworks - Devoxx France 2013
Comparing JVM Web Frameworks - Devoxx France 2013Comparing JVM Web Frameworks - Devoxx France 2013
Comparing JVM Web Frameworks - Devoxx France 2013Matt Raible
 
API Caching, why your server needs some rest
API Caching, why your server needs some restAPI Caching, why your server needs some rest
API Caching, why your server needs some restLuis Cipriani
 
How To Create Presentation Slides That Are Out Of This World by @slidecomet @...
How To Create Presentation Slides That Are Out Of This World by @slidecomet @...How To Create Presentation Slides That Are Out Of This World by @slidecomet @...
How To Create Presentation Slides That Are Out Of This World by @slidecomet @...HighSpark | Visual Storytelling Agency
 
7 Tips to Beautiful PowerPoint by @itseugenec
7 Tips to Beautiful PowerPoint by @itseugenec7 Tips to Beautiful PowerPoint by @itseugenec
7 Tips to Beautiful PowerPoint by @itseugenecEugene Cheng
 

Andere mochten auch (9)

Tips for creating a Self Organizing Teams
Tips for creating a Self Organizing TeamsTips for creating a Self Organizing Teams
Tips for creating a Self Organizing Teams
 
Learn Dashing Widget in 90 minutes
Learn Dashing Widget in 90 minutesLearn Dashing Widget in 90 minutes
Learn Dashing Widget in 90 minutes
 
WSO2 para o Governo Brasileiro
WSO2 para o  Governo BrasileiroWSO2 para o  Governo Brasileiro
WSO2 para o Governo Brasileiro
 
Comparing JVM Web Frameworks - Devoxx France 2013
Comparing JVM Web Frameworks - Devoxx France 2013Comparing JVM Web Frameworks - Devoxx France 2013
Comparing JVM Web Frameworks - Devoxx France 2013
 
Rails Best Practices
Rails Best PracticesRails Best Practices
Rails Best Practices
 
RequireJS & Handlebars
RequireJS & HandlebarsRequireJS & Handlebars
RequireJS & Handlebars
 
API Caching, why your server needs some rest
API Caching, why your server needs some restAPI Caching, why your server needs some rest
API Caching, why your server needs some rest
 
How To Create Presentation Slides That Are Out Of This World by @slidecomet @...
How To Create Presentation Slides That Are Out Of This World by @slidecomet @...How To Create Presentation Slides That Are Out Of This World by @slidecomet @...
How To Create Presentation Slides That Are Out Of This World by @slidecomet @...
 
7 Tips to Beautiful PowerPoint by @itseugenec
7 Tips to Beautiful PowerPoint by @itseugenec7 Tips to Beautiful PowerPoint by @itseugenec
7 Tips to Beautiful PowerPoint by @itseugenec
 

Ähnlich wie Gran Sasso Science Institute | HTML5 the New Frontier of the Web

Angular jS Introduction by Google
Angular jS Introduction by GoogleAngular jS Introduction by Google
Angular jS Introduction by GoogleASG
 
Web Development Today
Web Development TodayWeb Development Today
Web Development Todaybretticus
 
Building the next generation of browser apps today
Building the next generation of browser apps todayBuilding the next generation of browser apps today
Building the next generation of browser apps todayRandy Williams
 
HTML5 & CSS3 refresher for mobile apps
HTML5 & CSS3 refresher for mobile appsHTML5 & CSS3 refresher for mobile apps
HTML5 & CSS3 refresher for mobile appsIvano Malavolta
 
Making Of PHP Based Web Application
Making Of PHP Based Web ApplicationMaking Of PHP Based Web Application
Making Of PHP Based Web ApplicationSachin Walvekar
 
HTML5 introduction for beginners
HTML5 introduction for beginnersHTML5 introduction for beginners
HTML5 introduction for beginnersVineeth N Krishnan
 
Web II - 01 - Introduction to server-side development
Web II - 01 - Introduction to server-side developmentWeb II - 01 - Introduction to server-side development
Web II - 01 - Introduction to server-side developmentRandy Connolly
 
Web development concepts using microsoft technologies
Web development concepts using microsoft technologiesWeb development concepts using microsoft technologies
Web development concepts using microsoft technologiesHosam Kamel
 
Ajax Abuse Todcon2008
Ajax Abuse Todcon2008Ajax Abuse Todcon2008
Ajax Abuse Todcon2008Jesse Rodgers
 
Front End Development | Introduction
Front End Development | IntroductionFront End Development | Introduction
Front End Development | IntroductionJohnTaieb
 
HTML5 Webinar - Mind Storm Software
HTML5 Webinar - Mind Storm SoftwareHTML5 Webinar - Mind Storm Software
HTML5 Webinar - Mind Storm SoftwareRomin Irani
 
SharePoint 2013 App Provisioning Models
SharePoint 2013 App Provisioning ModelsSharePoint 2013 App Provisioning Models
SharePoint 2013 App Provisioning ModelsShailen Sukul
 
The future of web development write once, run everywhere with angular js an...
The future of web development   write once, run everywhere with angular js an...The future of web development   write once, run everywhere with angular js an...
The future of web development write once, run everywhere with angular js an...Mark Leusink
 
The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...Mark Roden
 

Ähnlich wie Gran Sasso Science Institute | HTML5 the New Frontier of the Web (20)

Angular jS Introduction by Google
Angular jS Introduction by GoogleAngular jS Introduction by Google
Angular jS Introduction by Google
 
HTML5 Refresher
HTML5 RefresherHTML5 Refresher
HTML5 Refresher
 
Html5
Html5Html5
Html5
 
Web Development Today
Web Development TodayWeb Development Today
Web Development Today
 
Building the next generation of browser apps today
Building the next generation of browser apps todayBuilding the next generation of browser apps today
Building the next generation of browser apps today
 
HTML5 & CSS3 refresher for mobile apps
HTML5 & CSS3 refresher for mobile appsHTML5 & CSS3 refresher for mobile apps
HTML5 & CSS3 refresher for mobile apps
 
Mobile Web
Mobile WebMobile Web
Mobile Web
 
Making Of PHP Based Web Application
Making Of PHP Based Web ApplicationMaking Of PHP Based Web Application
Making Of PHP Based Web Application
 
HTML5 introduction for beginners
HTML5 introduction for beginnersHTML5 introduction for beginners
HTML5 introduction for beginners
 
HTML5 Comprehensive Guide
HTML5 Comprehensive GuideHTML5 Comprehensive Guide
HTML5 Comprehensive Guide
 
Web II - 01 - Introduction to server-side development
Web II - 01 - Introduction to server-side developmentWeb II - 01 - Introduction to server-side development
Web II - 01 - Introduction to server-side development
 
Web development concepts using microsoft technologies
Web development concepts using microsoft technologiesWeb development concepts using microsoft technologies
Web development concepts using microsoft technologies
 
Ajax Abuse Todcon2008
Ajax Abuse Todcon2008Ajax Abuse Todcon2008
Ajax Abuse Todcon2008
 
Food borne human diseases
Food borne human diseasesFood borne human diseases
Food borne human diseases
 
Front End Development | Introduction
Front End Development | IntroductionFront End Development | Introduction
Front End Development | Introduction
 
HTML5 Webinar - Mind Storm Software
HTML5 Webinar - Mind Storm SoftwareHTML5 Webinar - Mind Storm Software
HTML5 Webinar - Mind Storm Software
 
SharePoint 2013 App Provisioning Models
SharePoint 2013 App Provisioning ModelsSharePoint 2013 App Provisioning Models
SharePoint 2013 App Provisioning Models
 
The future of web development write once, run everywhere with angular js an...
The future of web development   write once, run everywhere with angular js an...The future of web development   write once, run everywhere with angular js an...
The future of web development write once, run everywhere with angular js an...
 
The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...The future of web development write once, run everywhere with angular.js and ...
The future of web development write once, run everywhere with angular.js and ...
 
Intro to Application Express
Intro to Application ExpressIntro to Application Express
Intro to Application Express
 

Mehr von Commit University

Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Commit University
 
Breaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdf
Breaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdfBreaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdf
Breaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdfCommit University
 
Accelerating API Development: A Pit Stop with Gin-Gonic in Golang-Slide.pdf
Accelerating API Development: A Pit Stop with Gin-Gonic in Golang-Slide.pdfAccelerating API Development: A Pit Stop with Gin-Gonic in Golang-Slide.pdf
Accelerating API Development: A Pit Stop with Gin-Gonic in Golang-Slide.pdfCommit University
 
Collaborazione, Decisionalità e Gestione della Complessità nel Tempo: cosa ...
Collaborazione, Decisionalità e Gestione della Complessità nel Tempo: cosa ...Collaborazione, Decisionalità e Gestione della Complessità nel Tempo: cosa ...
Collaborazione, Decisionalità e Gestione della Complessità nel Tempo: cosa ...Commit University
 
Commit - Qwik il framework che ti stupirà.pptx
Commit - Qwik il framework che ti stupirà.pptxCommit - Qwik il framework che ti stupirà.pptx
Commit - Qwik il framework che ti stupirà.pptxCommit University
 
Sviluppare da zero una Angular Web App per la PA
Sviluppare da zero una Angular Web App per la PASviluppare da zero una Angular Web App per la PA
Sviluppare da zero una Angular Web App per la PACommit University
 
Backstage l'Internal Developer Portal Open Source per una migliore Developer ...
Backstage l'Internal Developer Portal Open Source per una migliore Developer ...Backstage l'Internal Developer Portal Open Source per una migliore Developer ...
Backstage l'Internal Developer Portal Open Source per una migliore Developer ...Commit University
 
Prisma the ORM that node was waiting for
Prisma the ORM that node was waiting forPrisma the ORM that node was waiting for
Prisma the ORM that node was waiting forCommit University
 
Decision-making for Software Development Teams - Commit University
Decision-making for Software Development Teams - Commit UniversityDecision-making for Software Development Teams - Commit University
Decision-making for Software Development Teams - Commit UniversityCommit University
 
Component Design Pattern nei Game Engine.pdf
Component Design Pattern nei Game Engine.pdfComponent Design Pattern nei Game Engine.pdf
Component Design Pattern nei Game Engine.pdfCommit University
 
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...Commit University
 
Prototipazione Low-Code con AWS Step Functions
Prototipazione Low-Code con AWS Step FunctionsPrototipazione Low-Code con AWS Step Functions
Prototipazione Low-Code con AWS Step FunctionsCommit University
 
KMM survival guide: how to tackle struggles between Kotlin and Swift
KMM survival guide: how to tackle struggles between Kotlin and SwiftKMM survival guide: how to tackle struggles between Kotlin and Swift
KMM survival guide: how to tackle struggles between Kotlin and SwiftCommit University
 
Da Vuex a Pinia: come fare la migrazione
Da Vuex a Pinia: come fare la migrazioneDa Vuex a Pinia: come fare la migrazione
Da Vuex a Pinia: come fare la migrazioneCommit University
 
Orchestrare Micro-frontend con micro-lc
Orchestrare Micro-frontend con micro-lcOrchestrare Micro-frontend con micro-lc
Orchestrare Micro-frontend con micro-lcCommit University
 
Fastify has defeated Lagacy-Code
Fastify has defeated Lagacy-CodeFastify has defeated Lagacy-Code
Fastify has defeated Lagacy-CodeCommit University
 

Mehr von Commit University (20)

Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)Crea il tuo assistente AI con lo Stregatto (open source python framework)
Crea il tuo assistente AI con lo Stregatto (open source python framework)
 
Breaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdf
Breaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdfBreaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdf
Breaking REST Chains_ A Fastify & Mercurius Pathway to GraphQL Glory.pdf
 
Accelerating API Development: A Pit Stop with Gin-Gonic in Golang-Slide.pdf
Accelerating API Development: A Pit Stop with Gin-Gonic in Golang-Slide.pdfAccelerating API Development: A Pit Stop with Gin-Gonic in Golang-Slide.pdf
Accelerating API Development: A Pit Stop with Gin-Gonic in Golang-Slide.pdf
 
Slide-10years.pdf
Slide-10years.pdfSlide-10years.pdf
Slide-10years.pdf
 
Collaborazione, Decisionalità e Gestione della Complessità nel Tempo: cosa ...
Collaborazione, Decisionalità e Gestione della Complessità nel Tempo: cosa ...Collaborazione, Decisionalità e Gestione della Complessità nel Tempo: cosa ...
Collaborazione, Decisionalità e Gestione della Complessità nel Tempo: cosa ...
 
Vue.js slots.pdf
Vue.js slots.pdfVue.js slots.pdf
Vue.js slots.pdf
 
Commit - Qwik il framework che ti stupirà.pptx
Commit - Qwik il framework che ti stupirà.pptxCommit - Qwik il framework che ti stupirà.pptx
Commit - Qwik il framework che ti stupirà.pptx
 
Sviluppare da zero una Angular Web App per la PA
Sviluppare da zero una Angular Web App per la PASviluppare da zero una Angular Web App per la PA
Sviluppare da zero una Angular Web App per la PA
 
Backstage l'Internal Developer Portal Open Source per una migliore Developer ...
Backstage l'Internal Developer Portal Open Source per una migliore Developer ...Backstage l'Internal Developer Portal Open Source per una migliore Developer ...
Backstage l'Internal Developer Portal Open Source per una migliore Developer ...
 
Prisma the ORM that node was waiting for
Prisma the ORM that node was waiting forPrisma the ORM that node was waiting for
Prisma the ORM that node was waiting for
 
Decision-making for Software Development Teams - Commit University
Decision-making for Software Development Teams - Commit UniversityDecision-making for Software Development Teams - Commit University
Decision-making for Software Development Teams - Commit University
 
Component Design Pattern nei Game Engine.pdf
Component Design Pattern nei Game Engine.pdfComponent Design Pattern nei Game Engine.pdf
Component Design Pattern nei Game Engine.pdf
 
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...
Un viaggio alla scoperta dei Language Models e dell’intelligenza artificiale ...
 
Prototipazione Low-Code con AWS Step Functions
Prototipazione Low-Code con AWS Step FunctionsPrototipazione Low-Code con AWS Step Functions
Prototipazione Low-Code con AWS Step Functions
 
KMM survival guide: how to tackle struggles between Kotlin and Swift
KMM survival guide: how to tackle struggles between Kotlin and SwiftKMM survival guide: how to tackle struggles between Kotlin and Swift
KMM survival guide: how to tackle struggles between Kotlin and Swift
 
Da Vuex a Pinia: come fare la migrazione
Da Vuex a Pinia: come fare la migrazioneDa Vuex a Pinia: come fare la migrazione
Da Vuex a Pinia: come fare la migrazione
 
Orchestrare Micro-frontend con micro-lc
Orchestrare Micro-frontend con micro-lcOrchestrare Micro-frontend con micro-lc
Orchestrare Micro-frontend con micro-lc
 
Fastify has defeated Lagacy-Code
Fastify has defeated Lagacy-CodeFastify has defeated Lagacy-Code
Fastify has defeated Lagacy-Code
 
SwiftUI vs UIKit
SwiftUI vs UIKitSwiftUI vs UIKit
SwiftUI vs UIKit
 

Kürzlich hochgeladen

ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONHumphrey A Beña
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Mark Reed
 
Karra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxKarra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxAshokKarra1
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfTechSoup
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Celine George
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPCeline George
 
How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17Celine George
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Celine George
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxAnupkumar Sharma
 
Q4 English4 Week3 PPT Melcnmg-based.pptx
Q4 English4 Week3 PPT Melcnmg-based.pptxQ4 English4 Week3 PPT Melcnmg-based.pptx
Q4 English4 Week3 PPT Melcnmg-based.pptxnelietumpap1
 
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxBarangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxCarlos105
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4MiaBumagat1
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfMr Bounab Samir
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Jisc
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for BeginnersSabitha Banu
 

Kürzlich hochgeladen (20)

ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
 
Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)Influencing policy (training slides from Fast Track Impact)
Influencing policy (training slides from Fast Track Impact)
 
LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptxLEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
LEFT_ON_C'N_ PRELIMS_EL_DORADO_2024.pptx
 
Karra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptxKarra SKD Conference Presentation Revised.pptx
Karra SKD Conference Presentation Revised.pptx
 
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdfInclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
Inclusivity Essentials_ Creating Accessible Websites for Nonprofits .pdf
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERP
 
How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17How to Add Barcode on PDF Report in Odoo 17
How to Add Barcode on PDF Report in Odoo 17
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17
 
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptxMULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
MULTIDISCIPLINRY NATURE OF THE ENVIRONMENTAL STUDIES.pptx
 
Q4 English4 Week3 PPT Melcnmg-based.pptx
Q4 English4 Week3 PPT Melcnmg-based.pptxQ4 English4 Week3 PPT Melcnmg-based.pptx
Q4 English4 Week3 PPT Melcnmg-based.pptx
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
Raw materials used in Herbal Cosmetics.pptx
Raw materials used in Herbal Cosmetics.pptxRaw materials used in Herbal Cosmetics.pptx
Raw materials used in Herbal Cosmetics.pptx
 
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptxBarangay Council for the Protection of Children (BCPC) Orientation.pptx
Barangay Council for the Protection of Children (BCPC) Orientation.pptx
 
ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4ANG SEKTOR NG agrikultura.pptx QUARTER 4
ANG SEKTOR NG agrikultura.pptx QUARTER 4
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for Beginners
 

Gran Sasso Science Institute | HTML5 the New Frontier of the Web

  • 1. Gran Sasso Science Institute | University of L’Aquila Ivano Malavolta HTML5: the new frontier of the web
  • 2. About me… Ivano Malavolta Post Doc researcher – Gran Sasso Science Institute www.ivanomalavolta.com
  • 3. Roadmap Anatomy of a web app Debugging (mobile) web apps HTML5 Maintainable web apps
  • 5. What is a Web App? An application built with web technologies that is accessible via a mobile browser and NOT EXCLUSIVELY through an app store The browser may be either the standard device browser or an embedded browser (Hybrid app)
  • 6. Anatomy of a Web App
  • 7. Setting up the Server As usual, it all starts with an HTTP request Then you need: •  Data •  A device detection mechanism [optional] •  The app itself
  • 8. Data Usually mobile apps do not talk directly with the database à do not even think about JDBC, drivers, etc! à  They pass through an application server and communicate via: •  standard HTTP requests for HTML content (eg PHP) •  REST-full services (XML, JSON, etc.) •  SOAP
  • 9. Data •  Data can be stored in any classical way: •  Relational •  Graph •  Key-value •  Document-based Latest trend à backend-as-a-service
  • 10. BaaS 1.  Developers build a visual model of their DB 2.  The service generates APIs and client-side libraries(compatible with Android, Windows Phone, etc.) 3.  The data produced/consumed in the app can be pushed/pulled to their DB •  Communication is handled via REST-based APIs
  • 11. Example of Baas software: BaasBox Main features: •  User management •  ACL •  Friendships •  Authentication via Facebook and Google+ •  Document-based data manegement (via OrientDB) •  Assets management (fotos, documents, or files) •  Push notifications The “Box” in BaasBox means that all the features are in a standalone server, just like a box. No Application Server, no Database Server, just a JVM and nothing more Rest API Web dashboard http://www.baasbox.com/
  • 12. Ok, but what about mobile apps? BROWSER <html> <head> <script src=” ...” /> </head> <body> ... NATIVE WRAPPER <html> <head> <script src=” ...” /> </head> <body> ... PLATFORM APIs NATIVE APP 01010101010101101010 1010101011011010 010101010101011101 010101010101011010 PLATFORM APIs Native Web Hybrid
  • 13. Native http://bit.ly/GWOaP1 PRO •  Lets you create apps with rich user interfaces and/or heavy graphics CONS •  Development Time •  Development Cost •  Ongoing Maintenance •  No portability (apps cannot be used on other platforms) PRO CONS
  • 14. Examples of native apps http://www.ea.com/it/ipad/nfs http://www.whatsapp.com/
  • 15. Web http://bit.ly/GWOaP1 PRO •  Offers fast development, simple maintenance, and full application portability •  One mobile web app works on any platform CONS •  Can’t handle heavy graphics •  Can’t access camera or microphone PRO CONS
  • 16. Examples of web apps http://asidemag.com http://amazon.com
  • 17. Hybrid http://bit.ly/GWOaP1 PRO •  Development speed of mobile web apps •  Device access and app store distribution of native apps CONS •  Can’t handle heavy graphics •  Requires familiarity with a mobile framework PRO CONS
  • 18. Examples of hybrid apps http://www.gmail.com http://flipboard.com
  • 19. Frascati Scienza QR code scanning In-app RSS feed reader Maps Non-linear layouts https://itunes.apple.com/it/app/frascati-scienza-scienziati/id686974321?mt=8
  • 21. My vision Mobile web seems to be the only long-term commercially viable platform for mobile FRAGMENTATION THE WEB USER EXPECTATIONS
  • 22. When you go native there are too many platforms to be supported FRAGMENTATION
  • 23. The web is the only platform that: •  works across devices •  apps share the same set of standards •  the same app can work also on a desktop THE WEB The web is an advanced technology: •  webGL •  Local storage management •  Positioning & mapping •  Real-time data •  Push, ...
  • 24. Users expect things to just work à they don’t care about what platform they have àthey simply expect that your app will be available for their device à YOU HAVE TO BE CROSS-PLATFORM USER EXPECTATIONS
  • 25. PhoneGap You develop your app using the usual three guys You use the same web view of the native OS •  iOS = UIWebView •  Android = android.webkit.WebView http://phonegap.com/blog/2013/06/20/coming-soon-phonegap30
  • 26. What is PhoneGap? The UI layer is a web browser view •  100% width •  100% height Headless web browser •  No URL bar •  No decorations •  No zooming •  No text selection
  • 27. It looks very similar to Apache Cordova… Adobe/Nitobi donated the PhoneGap codebase to the Apache foundation à wider audience and contributors à transparent governance Better documentation à easier contributions for companies Apache Licensing There was only one problem.... trademark ambiguity à CORDOVA PhoneGap is a distribution of Apache Cordova
  • 28. Roadmap Anatomy of a web app HTML5
  • 29. HTML 5 HTML5 will be the new standard for HTML HTML5 is still a work in progress W3C final recomendation: 2020 Top browsers support many (not all) of the new HTML5 elements http://mobilehtml5.org http://caniuse.com
  • 30. What is HTML5? It is an extension of HTML/XHTML 4 •  with new more semantically rich elements <article>, <footer>, <header>, <nav>, <section> •  deprecating tags & attributes <center>, <font>, <frame>, height, width •  introducing new attributes placeholder, form •  additional APIs geolocalization, video, audio HTML5 Markup JavaScript CSS3 Multimedia
  • 31. The minimal HTML5 page <!DOCTYPE  html>   <html>    <head>    <title>Title</title>   </head>    <body>   …   </body>   </html>  
  • 32. New Structural Tags Main Goal: separate presentation from content •  Poor accessibility •  Unnecessary complexity •  Larger document size Most of the presentational features from earlier versions of HTML are no longer supported New structural tags
  • 33. New Structural Tags <header> header region of a page or section <footer> footer region of a page or section <nav> navigation region of a page or section <section> logical region of a page <article> a complete piece of content <aside> secondary or related content http://bit.ly/JCnuQJ
  • 34. Custom Data Attributes Can be used to add metadata about any element within an HTML5 page They are ignored by the validator for HTML5 documents They all start with the data- pattern They can be read by any browser using Javascript via the getAttribute() method These attributes are used by many JavaScript frameworks
  • 35. Forms Main Goal: reduce the Javascript for validation and format management Example: Forms
  • 36. Form Input Types Form input types degrade gracefully à Unknown input types are treated as text-type http://bit.ly/I65jai
  • 37. Audio <audio> : a standard way to embed an audio file on a web page <audio controls> <source src="song.ogg" type="audio/ogg" /> <source src="song.mp3" type="audio/mpeg" /> Not Supported </audio> Multiple sources à the browser will use the first recognized format Audio
  • 38. Audio Javascript API HTML5 provides a set of Javascript APIs for interacting with an audio element For example: play() pause() load() currentTime ended volume… à http://www.w3.org/wiki/HTML/Elements/audio
  • 39. Video <video> : a standard way to embed a video file on a web page <video width="320" height="240" controls> <source src="movie.mp4" type="video/mp4" /> <source src="movie.ogg" type="video/ogg" /> Not Supported </video> Multiple sources à the browser will use the first recognized format Video
  • 40. Video Javascript API HTML5 provides a set of Javascript APIs for interacting with a video element For example: play() pause() load() currentTime ended volume… à http://www.w3.org/wiki/HTML/Elements/video
  • 41. Accelerometer There are 4 ways to store data locally in Cordova: •  Web storage •  Local Storage •  Session Storage •  WebSQL •  Indexed DB •  File System Access Local storage and file system access Web storage, WebSQL, and IndexedDB conform to W3C specifications and are provided by the browser itself File system access API conforms to its corresponding W3C specification
  • 42. Web Storage LocalStorage stores data in key/value pairs persists across browser sessions SessionStorage stores data in key/value pairs data is erased when a browser session ends
  • 43. WebSQL relational DB support for tables creation, insert, update, … transactional persists across browser sessions Its evolution is called IndexedDB
  • 44. WebSQL It provides you a structured SQL relational database You have to setup a DB schema You can then perform classical SQL queries tx.executeSql("SELECT  *  FROM  User“,  [],    function(tx,  result)  {      //  callback  code   });  
  • 45. IndexedDB •  It tries to combine Web Storage and WebSQL •  You can save data as key/value pairs •  You can define multiple DBs •  Good Performance data is indexed asynchronous ! it does not block the UI You can see a store as a big SQL table with only key/value pairs à you don’t need to define a schema upfront
  • 46. Considerations You will likely use more than one API in combination à Use the right API for the right job Local Storage •  it is not transactional à race conditions •  very simple API, no schema •  only String data à performance issues for complex data due to JSON serialization •  session storage will be cleared after the app is closed •  limited quota
  • 47. Considerations WebSQL •  SQL-based à fast and efficient •  transactional à more robust •  asynchronous à does not block the UI •  rigid data structure à data integrity vs agility •  limited quota
  • 48. Considerations IndexedDB •  simple data model à easy to use •  transactional à more robust •  asynchronous à does not block the UI •  good search performance à indexed data •  data is unstructured à integrity problems •  limited quota •  not supported by every platform (e.g., iOS)
  • 50. Geolocalization Gets Latitude and Longitude from the user’s browser There is also a watchPosition method wich calls a JS function every time the user moves Geolocalization
  • 51. Example function getLocation() { if(navigator.geolocation) { navigator.geolocation.getCurrentPosition(showPosition); } else { console.log(‘no geolocalization’); } } function showPosition(position) { console.log(position.coords.latitude); console.log(position.coords.longitude); }
  • 52. WebSockets Bidirectional, full-duplex communication between devices and server Specifically suited for chat, videogames, drawings sharing, real-time info Requires a Web Socket Server to handle the protocol Web sockets
  • 53. WebSockets - Overview 1.  Client notifies websocket server (EventMachine) of an event, giving ids of recipients 2.  The server notifies all the active clients (subscribed to that type of event) 3.  Clients process event when given recipient Id matches the client’s one http://bit.ly/Ixcupi
  • 54. Alternative - Polling via AJAX + Near real-time updates (not purely real-time) + easy to implement + no new technologies needed -  they are requested from the client and cause increased network traffic -  AJAX requests generally have a small payload and relatively high amount of http headers (wasted bandwith)
  • 55. Canvas Canvas allows you to draw anything inside the browser http://bit.ly/Ie4HKu http://bit.ly/LUKXkr http://bit.ly/LULa79 http://bit.ly/LC8AgY Canvas
  • 56. Canvas It uses nothing more than JavaScript and HTML à no external plugins, no libraries, etc. You can create lines, use images, use text, apply transformations, etc. http://bit.ly/KsKLv1
  • 57. Canvas example: the Impavida project http://www.impavida.com/ placeholder
  • 58. Web Workers Javascript is a single-threaded language à If a tasks take a lot of time, users have to wait Web Workers provide background processing capabilities to web applications They typically run on separate threads à apps can take advantage of multicore CPUs Web workers
  • 59. Web Workers Web Workers can be used to: •  prefetch data from the Web •  perform other ahead-of-time operations to provide a much more lively UI. Precious on mobile Web applications because of the slow network speed
  • 60. Web Workers Any JS file can be launched as a worker Example of Web Worker declaration: var worker = new Worker(“worker.js”); In order to be independent from other workers, each worker script cannot access the DOM
  • 61. Web Workers The main JS script can communicate with workers via postMessage() calls: $(‘#button’).click(function(event) { $(‘#output’).html(“starting”); worker.postMessage(“start”); }); worker.onmessage = function(event) { $(‘#output’).html(event.data); }
  • 62. Web Workers The web worker script can post back messages to the main script: onmessage = function(event) { if(event.data === “start”) { var result; // do something with result postMessage(result); } }
  • 63. Roadmap Anatomy of a web app Debugging (mobile) web apps HTML5
  • 64. The killer app! •  Check console •  Breakpoints •  Update the DOM at run-time •  Access to all local DBs •  Network profiling •  CPU and memory profiling •  Monitor event listeners •  Monitor elements’ rendering time
  • 65. Desktop Browser •  very quick •  very handy functions •  see Chrome’s Web Development Tools •  Breakpoints PRO •  browsers’ small differences and bugs •  cannot test all mobile-specific functionalities •  you need PhoneGap shims CONS
  • 67. Ripple •  very quick •  can use Chrome’s Web Development Tools •  You can test PhoneGap’s API from the Desktop •  browsers’ small differences and bugs •  cannot test the interaction with external apps PRO CONS It is based on Ripple, a Chrome plugin for mobile dev from PhoneGap 3.0.0, you need to use the Ripple available at Apache npm  install  -­‐g  ripple-­‐emulator   ripple  emulate  
  • 69. Simulator •  Officially supported by platform vendors •  You use the “real” device’s browser PRO •  device’s performance is not considered •  this is iOS-specific •  Android’s emulator is a joke •  device’s capabilities are only simulated CONS
  • 70. On device •  accurate •  still handy •  real performance tests •  real browser tests PRO •  Deployment takes some time (~6 seconds for iOS) CONS
  • 71. Remote Debugging From iOS 6, Apple provided Mobile Safari with a remote web inspector à You can debug your app by using the classical web inspector of Desktop Safari It can connect both to •  The iOS emulator •  The real device Since Android 4.4, this feature is available via Chrome’s web dev kit
  • 72. Mobile debugging reference table Make a favor to yourself, don’t debug craftsman way: console.log()  +  alert()   iOS Android Desktop Browser Ripple Device/emulator Safari Web Inspector X Chrome Web Inspector X
  • 73. Roadmap Anatomy of a web app Debugging (mobile) web apps HTML5 Maintainable web apps
  • 74. Roadmap •  Introduction •  Backbone •  Require JS •  Handlebars •  Combining backbone, Require, and Handlebars
  • 75. Introduction We are building apps, not web sites If your code is not structured: •  it is extremely easy that your web app becomes a big mess of HTML + CSS + JavaScript •  maintaining each part of your app asks for a deep analysis of ALL its aspects (logic, presentation, etc.) •  you may waste a whole day due to a missing  <  
  • 76. What we want to avoid Imagine yourself trying to change either: •  how a movie should be rendered in your app •  the REST API providing info about movies
  • 77. Roadmap •  Introduction •  Backbone •  Require JS •  Handlebars •  Combining backbone, Require, and Handlebars
  • 79. Why Backbone From the Backbone website... manipulate the DOM lists of models represent data
  • 80. Who is using Backbone?
  • 81. Backbone events Basically, each object can: •  listen to events •  trigger events
  • 82. Models Models represent your data Each model represents a data type in your app, together with the logic surrounding it, like: •  persistence •  conversions •  validation •  computed properties •  access control MVC: Notify their observers about their state using the Observer pattern
  • 83. Example of model http://goo.gl/UOahsP custom method setting an attribute custom method invocation constructor default attributes getting an attribute
  • 85. Collections Collections are ordered sets of models You can: •  bind change events to be notified when any model in the collection has been modified •  listen for add and remove events •  fetch the collection from the server (or other persistence layers) •  find models or filter collections themeselves The model attribute of a collection represents the kind of model that can be stored in it Any event that is triggered on a model in a collection will also be triggered on the collection directly MVC: Notify their observers about state using the Observer pattern (same as models)
  • 86. Example of collection http://goo.gl/UOahsP type of stored models Instance of collection
  • 88. Views Views represent and manage the visible parts of your application They are also used to •  listen to interaction events •  and react accordingly views can be rendered at any time, and inserted into the DOM you get high-performance UI rendering with as few reflows and repaints as possible MVC: observe models, and update itself according to the state of the models + manage user inputs (it’s a controller, to this sense)
  • 89. Example of view Events map “event_name selector”: callback Events callbacks create the DOM subtree
  • 91. The router Backbone.Router  provides methods for routing client-side pages, and connecting them to actions and events At a minimum, a router is composed of two main parts: routes an hash that pairs routes to actions actions JS functions triggered when certain routes are navigated
  • 92. Example of router routes map routing functions
  • 93. Backbone-based workflow •  You organize your interface into logical views backed by models •  Each view can be updated independently when the model changes, without having to redraw the page You can bind your view‘s render() function to the model‘s "change” event à now everywhere that model data is displayed in the UI, it is always up to date
  • 94. Roadmap •  Introduction •  Backbone •  Require JS •  Handlebars •  Combining backbone, Require, and Handlebars
  • 95. Why Require JS We are building apps, not website We need well-specified and isolated JS files/modules Code complexity grows as the app gets bigger à we need some sort of #include/import/require   à ability to load nested dependencies
  • 96. What we want to avoid uncontrolled scripts poor control flow understanding
  • 97. Require JS RequireJS is a JavaScript file and module loader Using a modular script loader like Require JS will improve the modularity of your code: à  speed in implementing changes à  better undestanding of the code Require JS allows modules to be loaded as fast as possible, even out of order, but evaluated in the correct dependency order It is built on the Module Pattern JavaScript file and module loader
  • 98. Module example Technically, it is simply a function that executes immediately
  • 99. Module VS script files A module is different from a traditional script file in that it defines a well-scoped object that avoids polluting the global namespace à its retained objects can be deleted by the GC It can explicitly list its dependencies and get a handle on those dependencies without needing to refer to global objects, but instead receive the dependencies as arguments to the function that defines the module VS
  • 100. Module definition Required modules (array) References to required modules Dependent module usage This function is called when zepto.js is loaded. If zepto.js calls define(), then this function is not fired until also zepto’s dependencies have loaded
  • 101. Require JS under the hoods... 1.  loads each dependency as a script tag, using head.appendChild() and waits for all dependencies to load 2.  computes the right order in which to call the functions that define the modules 3.  calls the module definition functions of each dependency in the right order main.js jQuery Backbone SpinJS MoviesCollection MovieModel MoviesView 1 2 3 4 5 6 7
  • 102. Roadmap •  Introduction •  Backbone •  Require JS •  Handlebars •  Combining backbone, Require, and Handlebars
  • 103. Why Handlebars We want to separate presentation from logic TRANSLATE TO: we don’t want to put any HTML element into JavaScript code separate logic from presentation Imagine yourself trying to change how a movie should be rendered in your app...
  • 104. Handlebars template A handlebars expression is {{ something  }}
  • 105. Template compilation   Handlebars.compile is used to compile a template Compiling = obtaining a JS object representing the template
  • 106. Templates population You have to execute a template with a context in order to get its corresponding HTML code
  • 107. handlebars summary Each Template can contain Expressions and Helpers operating on them The main helpers are: •  with   •  each   •  if  /  else  /unless   You can define your own Helpers that operate on expressions, they return HTML code A template can be (pre)-compiled and must be executed with a context in order to return the final HTML fragment
  • 108. Example of built-in helper It renders the block if its argument is not equal to false,  undefined,  null,  []   If / Else <div  class="entry“>   <h1>{{title}}</h1>   {{#if  author}}    <h2>By  {{firstName}}  {{lastName}}</h2>   {{#else}}    <h2>Unknown  author</h1>     {{/if}}   {  title:  "My  first  post!",          author:  undefined  }   }     <div  class="entry“>   <h1>My  first  post!</h1>   <h2>Unknown  author</h2>   </div>    
  • 109. Roadmap •  Introduction •  Backbone •  Require JS •  Handlebars •  Combining backbone, Require, and Handlebars
  • 110. Combining Backbone, Require, and Handlebars Handlebars templates can be seen as special Require modules So we can have the following: •  a separate HTML5 file for each template •  a Backbone view can have a dependency to each template •  the template can be executed by using a JSON object of the Backbone model as context
  • 111. Example Dependency to template HTML file It contains a string Compiled template Execution of the template
  • 112. How I structure my mobile apps
  • 113. I implemented all best practices and advices in this presentation in a generic app template available here: https://github.com/iivanoo/cordovaboilerplate
  • 115. + 39 380 70 21 600 Contact Ivano Malavolta | Gran Sasso Science Institute iivanoo ivano.malavolta@univaq.it www.ivanomalavolta.com