THE NEW (NEW) MOBILE WEB
Johannes Brodwall
Intro
“You need a native app
if…”
Notifications
Showcase
8
9
Could you do this in
pure web app?
https://openright-
mobile.herokuapp.com/
Write once,
test everywhere
Five things you actually
can do well on the web
1. App-y-ness
2. Sensors
3. Offline
4. Camera
5. Push notifications
But first:
Mobile web debugging
Appy-ness
Add to Home Screen
Icons and standalone mode
Toolbar
Card style
Sensors/actuators
Location
Accerelometer
Sound
Vibration
Offline
• Appcache
• IndexedDb
• Server-sent events
• (Backend)
Camera
58
Push notifications
Some challenges
Is this cool?
“You need a native app
if…”
TAKK FOR MEG
Johannes.Brodwall@SopraSteria.com
http://johannesbrodwall.com
http://smidigalliansen.no
http://twitter.com/jhannes

The new new mobile web

Editor's Notes

  • #44 box "Client" participant webpage participant IndexedDb participant EventSource end box box "Server" participant MessageServlet end box webpage -> EventSource: GET /messages EventSource -> MessageServlet: GET /messages [text/event-source] MessageServlet -> EventSource: Last message was at 5 PM EventSource -> webpage: event streamStarting webpage -> IndexedDb: Find last message webpage <-- IndexedDb: Last message was at 4:34 PM webpage -> MessageServlet: GET /messages startingAt 4:34 PM until 5 PM webpage -> IndexedDb: Store messages webpage -> webpage: show all messages in IndexedDb ... [-> MessageServlet: POST /message MessageServlet -> EventSource: event message webpage <- EventSource: event message webpage -> IndexedDb: store message webpage -> webpage: prepend message to chat
  • #67 actor User box "Client" participant webpage participant serviceworker participant browser end box box "Server" participant MessageServlet participant SubscriptionServlet end box participant "Google Cloud Messaging" as GCM webpage -> serviceworker: start webpage -> browser: subscribe browser -> GCM: subscribe webpage <-- browser: subscription webpage -> SubscriptionServlet: subscription ... [-> MessageServlet: New message MessageServlet -> SubscriptionServlet: notify subscribers SubscriptionServlet -> GCM: POST /gcm/send GCM -> serviceworker: event push serviceworker -> browser: showNotification browser -> User: Show notification icon User -> serviceworker: event notificationclick serviceworker -> browser: openWindow /mobile/#chats
  • #80 actor User box "Client" participant webpage participant serviceworker participant browser end box box "Server" participant MessageServlet participant SubscriptionServlet end box participant "Google Cloud Messaging" as GCM webpage -> serviceworker: start webpage -> browser: subscribe browser -> GCM: subscribe webpage <-- browser: subscription webpage -> SubscriptionServlet: subscription ... [-> MessageServlet: New message MessageServlet -> SubscriptionServlet: notify subscribers SubscriptionServlet -> GCM: POST /gcm/send GCM -> serviceworker: event push serviceworker -> browser: showNotification browser -> User: Show notification icon User -> serviceworker: event notificationclick serviceworker -> browser: openWindow /mobile/#chats