Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Data: online and off
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Phil Nash
September 21, 2015
Programming
0
170
Data: online and off
Phil Nash
September 21, 2015
Tweet
Share
More Decks by Phil Nash
See All by Phil Nash
Four steps from JavaScript to TypeScript
philnash
3
550
JavaScript Apps Go Intl - GIDS Live 2021
philnash
2
350
You're on Mute! WebRTC and our Lives on Screen - GIDS Live 2021
philnash
1
360
Better API DX with a CLI - APIdays Jakarta
philnash
0
430
The trouble with webhooks - at Apidays Live Hong Kong
philnash
2
270
Four steps from JavaScript to TypeScript
philnash
0
470
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.6k
The trouble with webhooks - at APIdays Singapore
philnash
0
390
What's going on with Project Fugu? at DevTalks Reimagined
philnash
0
610
Other Decks in Programming
See All in Programming
Docコメントで始める簡単ガードレール
keisukeikeda
1
110
PostgreSQL を使った快適な go test 環境を求めて
otakakot
0
540
どんと来い、データベース信頼性エンジニアリング / Introduction to DBRE
nnaka2992
1
280
Claude Codeセッション現状確認 2026福岡 / fukuoka-aicoding-00-beacon
monochromegane
4
420
オブザーバビリティ駆動開発って実際どうなの?
yohfee
3
830
Codexに役割を持たせる 他のAIエージェントと組み合わせる実務Tips
o8n
4
1.3k
「抽象に依存せよ」が分からなかった新卒1年目の私が Goのインターフェースと和解するまで
kurogenki
0
110
モジュラモノリスにおける境界をGoのinternalパッケージで守る
magavel
0
3.5k
API Platformを活用したPHPによる本格的なWeb API開発 / api-platform-book-intro
ttskch
1
130
AI時代のソフトウェア開発でも「人が仕様を書く」から始めよう-医療IT現場での実践とこれから
koukimiura
0
140
20260313 - Grafana & Friends Taipei #1 - Kubernetes v1.36 的開發雜記:那些困在 Alpha 加護病房太久的 Metrics
tico88612
0
170
encoding/json/v2のUnmarshalはこう変わった:内部実装で見る設計改善
kurakura0916
0
400
Featured
See All Featured
The Curse of the Amulet
leimatthew05
1
9.9k
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
60
42k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.4k
Exploring anti-patterns in Rails
aemeredith
2
290
Leading Effective Engineering Teams in the AI Era
addyosmani
9
1.7k
Git: the NoSQL Database
bkeepers
PRO
432
66k
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.2k
jQuery: Nuts, Bolts and Bling
dougneiner
65
8.4k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
11
860
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
141
35k
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
240
Believing is Seeing
oripsolob
1
80
Transcript
DATA: ONLINE AND OFF
Phil Nash @philnash http:/ /philna.sh
[email protected]
DATA: ONLINE AND OFF
OFFLINE FIRST
Offline first An application that treats the network as an
enhancement
Not offline first • Graceful failure to network requests •
Just saving data client side
None
None
THINGS TO CONSIDER
ASSETS
SERVICE WORKER
None
USER DATA
None
DATA: ONLINE AND OFF
Data: online and off • Traditional application data storage •
Traditional vs offline first • Browser based data storage • Offline first and data
TRADITIONAL APPLICATION DATA STORAGE
GET / POST
Traditional application data storage 1. POST data to a server
2. Server stores data in a database 1. GET request for data 2. Server interprets request and delivers
OFFLINE?
TRADITIONAL VS OFFLINE FIRST
INTERACT LOCALLY
Interact locally • Save data locally • Retrieve data from
local cache
Interact locally • Crazy fast! • The network doesn't matter
THEN SYNC
Sync • People have multiple devices • Good as a
backup
Sync • Can be asychronous • Can be intentional •
Requires network
DATA STORAGE IN THE FRONT END
LOCALSTORAGE
LocalStorage • Simple key value store • Synchronous (slow)
WEBSQL
WEBSQL
INDEXEDDB
IndexedDB • Asynchronous • o_O
MAKING DATA OFFLINE FIRST
Making data offline first We need something that is: •
Easily distributed • Eventually consistent • Resolves conflicts • Web friendly
None
CouchDB Apache CouchDB™ is a database that uses JSON for
documents, JavaScript for MapReduce indexes, and regular HTTP for its API
None
PouchDB • CouchDB for the browser/Node • Wraps IndexedDB or
WebSQL • LocalStorage adapter available as a plugin
DEMO
Offline first • The time for offline first is now
• Distributing data like this requires a change of mindset • Not all application data needs to be stored this way
Help me! On a scale of 0 to 10, how
likely is it that you would recommend this talk to a friend or colleague? 0203 322 5761
Thanks! @philnash http:/ /philna.sh
[email protected]
On a scale of 0
to 10, how likely is it that you would recommend this talk to a friend or colleague? 0203 322 5761