progressive web apps

46
Web VS. Native Progressive Web Apps

Upload: kian-peymani

Post on 16-Apr-2017

38 views

Category:

Mobile


1 download

TRANSCRIPT

Page 1: Progressive web apps

Web VS. Native

Progressive Web Apps

Page 2: Progressive web apps

@Kianenigma

@ZConf 2016

@Kianenigma

Page 3: Progressive web apps

Web VS. Native

Page 4: Progressive web apps

With Desktop … it went good

Page 5: Progressive web apps

With Mobile … Not that goodWhat happened?

Page 6: Progressive web apps

Dark days

Page 7: Progressive web apps

Apache cordova

Phonegap Backbone JQuery

Page 8: Progressive web apps

Apache cordova

Acceptable mobile appsWith some ~30mb APK

Page 9: Progressive web apps

brighter days …

Page 10: Progressive web apps

● Real Native Components● No Webview => Native Performance ● No code generation (xamiran) => Truly cross platform● Maintainable code code thanks to typescript and es6 support

Page 11: Progressive web apps

Back to the main problem:

Web wasn’t getting The attention it

wanted WHY ?

Page 12: Progressive web apps

DO NOT HELP us reach USERS THE help us look like native

All of the technologies mentioned ( )

We assumed, since native apps are doing better, it’s good to imitate

Page 13: Progressive web apps

web, as it currently is, is much better

We forgot that

WHY ?

Page 14: Progressive web apps

With the web● We reach, just with a URL ● We can have progressive updates,

with no user interaction

With Native● OS specific market ● Annoying updates

● 0 new app per month● Top three app (winner takes all)

● +50 new sites per month● Randomly distributed

Page 15: Progressive web apps

Distributing native software is hard.

Web can solve this

Page 16: Progressive web apps

We really shouldn’t have changed the web

We JUST have to make itMore PROGRESSIVE

Page 17: Progressive web apps

First, the difference between mobile and desktop

Most of us made the native => web transition on desktop

Page 18: Progressive web apps

Enabling technology for this transition

Desktop: AJAX ( or … ? ) Mobile: ???

Page 19: Progressive web apps

AJAX was not enough in mobile

Mobile apps keep the user engaged with their functionality

87%

13%

Platform

Time

Page 20: Progressive web apps

functi

onali

ty

reachability

Progressive

Page 21: Progressive web apps

Web VS. Native

Progressive Web Apps

Page 22: Progressive web apps

@Kianenigma

@ZConf 2016

@Kianenigma

Page 23: Progressive web apps

How to be a progressive web app? 1. Responsive

2. Fast Load3. Work offline4. Engaging

Page 24: Progressive web apps

{ Responsive view }We all know its

Hard But

possible

Page 25: Progressive web apps

How to be a progressive web app? 1. Responsive

2. Fast Load3. Work offline4. Engaging

Page 26: Progressive web apps

Load fast

Mobile networkCan take upto 2 sec to connect We lose more that 40% of usersWith more than 3 sec

Minimal optimized frameworks

Page 27: Progressive web apps

How to be a progressive web app? 1. Responsive

2. Fast Load3. Work offline4. Engaging

Page 28: Progressive web apps

Offline native app

Work Offline

Page 29: Progressive web apps

Offline Web

Or even worse...

Page 30: Progressive web apps

Your Darkest daysLie-fi

URBAN Dictionary: Lie-Fi. When your phone or tablet indicates that you are connected to a wireless network, however you are still unable to load webpages or use any internet ...

Page 31: Progressive web apps
Page 32: Progressive web apps

Introducing

Service workers

1. Run on background 2. Programmable Proxy for HTTP

requests

Page 33: Progressive web apps

Introducing

Service workers

1. Run on background 2. Proxy all HTTP requests

Cache - Static content- User data- App shell

Page 34: Progressive web apps

How to be a progressive web app? 1. Responsive

2. Fast Load3. Work offline4. Engaging

Page 35: Progressive web apps

Installable

Manifest.json

background- Sync- Notification - etc.

- Icon- Splash screen

{ "name": "My App", "short_name": "My App", "icons": [...] "start_url": "/", "display": "standalone", "background_color": "#3f51b5", "theme_color": "#3f51b5"}

Page 36: Progressive web apps

How to be a progressive web app? 1. Responsive

2. Fast Load3. Work offline4. Engaging

Page 38: Progressive web apps

Appendix

More details

Page 40: Progressive web apps

1. Browsers shipping sw + manifest as we speak : chrome / firefox / opera / samsung internet

2. Under development : edge 3. Just considering it : safari

A dark secret : ios

Page 41: Progressive web apps

1. Local storage : easy, clean, sufficient 2. Session storage : perhaps too easy! 3. Index db : seems messy! Use wrappers, like dexie.js

Storages

Page 42: Progressive web apps

Visit pwa.rocks

implementations

Page 43: Progressive web apps

Example: Ali-Express ( case study )● 104% for new users across all browsers● 82% increase in iOS conversion rate ● 2X more pages visited per session per user

across all browsers ● 74% increase in time spent per session across

all browsers

Page 44: Progressive web apps

Why is this important?

A Business case

● Reach => More ● Acquisition / cost => More ● Conversion => Improved

How do we start● Ground up ( konga ) ● A simple version ( air berlin / wp -

80ms load time )● One feature (Booking )

Page 45: Progressive web apps

A Business case

Page 46: Progressive web apps

Question ?