Over the years developers were used to thing that web is not user-friendly, performance efficient and powerful as native apps. But things have been changed so far; now you can build offline applications with notifications, Bluetooth and camera access and so on. Web development is great again.
- Quick startup - I will show how to prioritize content loading in the application to show users meaningful pixels as soon as possible
- Progressive enhancement - I will encourage you to use maximum of the platform but still support earlier browsers
- Offline application - here I will explain how you can easily make your web application working offline
- Push Notifications - one of the best way to increase conversion of your application and now it's possible on the web. I am going to show how to do it right with few steps.
- Experimental APIs - I will show how to sign in once on all your devices with Credential API, use native share menu and make payments in few clicks
48. Browser quota limits
6% of free disk
space per
origin
10% of free
disk space
(shared
across
eTLD+1)
at least 10%
of free disk
space
8GB: 10MB
32GB: 50MB
128GB: 250MB
>128GB: 500MB
63. self.addEventListener('push', event => {
let data;
if (event.data) {
data = event.data.json();
} else {
// fetch data from server
}
self.registration.showNotification(data.title, {
body: data.body, icon: data.icon, tag: data.tag
});
});
Listen For Messages
64. self.addEventListener('push', event => {
let data;
if (event.data) {
data = event.data.json();
} else {
// fetch data from server
}
self.registration.showNotification(data.title, {
body: data.body, icon: data.icon, tag: data.tag
});
});
Listen For Messages
65. {
"body": "Did you make a $1,000,000 purchase at Dr. Evil...",
"icon": "images/card.png",
"vibrate": [200, 100, 200, 100, 200, 100, 400],
"tag": "request",
"actions": [
{ "action": "yes", "title": "Yes", "icon": "images/yes.png" },
{ "action": "no", "title": "No", "icon": "images/no.png" }
]
}
86. const cred = new FederatedCredential({
id: id,
name: name,
provider: 'https://accounts.google.com',
iconURL: iconUrl
});
navigator.credentials.store(cred);
Credential Management API
87. navigator.credentials.get({
password: true,
federated: {
providers: [
'https://accounts.google.com',
'https://www.facebook.com'
]
},
unmediated: true // `unmediated: true` lets the user automatically sign in
}).then(cred => {
if (cred) // auto sign-in possible
else // auto sign-in not possible
});
Credential Management API
89. Enable users to sign in with just one
tap
Remember the federated account
the user has used to sign in with
Sign users back in when a session
expires
93. const request = new PaymentRequest(
methodData, // required payment method data
details, // required information about transaction
options // optional parameter for things like shipping, etc.
);
Payment Request API
119. 104% for new users across all browsers
82% increase in iOS conversion rate
2X more pages visited per session
74% increase in time spent per session
across all browsers
Live: https://aliexpress.com Source: https://developers.google.com/web/showcase/2016/aliexpress
120. 76% higher conversions across browsers
14% more monthly active users on iOS,
30% on Android
4X higher interaction rate from Add to
Homescreen
Live: http://www.alibaba.com Source: https://developers.google.com/web/showcase/2016/alibaba
121. 38% more conversions
40% lower bounce rate
10% longer average session
30% faster page load
Live: https://housing.com Source: https://developers.google.com/web/showcase/2016/housing
122. Source: https://developers.google.com/web/progressive-web-apps/checklist
Site is served over HTTPS
Pages are responsive on tablets &
mobile devices
The start URL (at least) loads while
offline
Metadata provided for Add to Home
screen
First load fast even on 3G
Site works cross-browser
Page transitions don't feel like they
block on the network
Each page has a URL
Progressive Web App Checklist