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
Progressive Web Apps
Search
Oscar Martin Cortez Martinez
December 15, 2018
Programming
0
42
Progressive Web Apps
Introduction to Progressive Web Apps - GDG Managua meetup 15 Dic. 2018
Oscar Martin Cortez Martinez
December 15, 2018
Tweet
Share
More Decks by Oscar Martin Cortez Martinez
See All by Oscar Martin Cortez Martinez
Python Packaging Without Pain
oscarmcm
0
180
Tools And Frameworks
oscarmcm
0
60
Web App Weekend - Firefox Apps
oscarmcm
0
39
RUBOTO
oscarmcm
1
82
Other Decks in Programming
See All in Programming
Git Rebase
bkuhlmann
11
1.6k
Implementing Design Systems in Swift
seyfoyun
2
500
ペパボOpenTelemetry革命
pyama86
2
180
Introducing Kotlin Multiplatform in an existing mobile app - Workshop Edition | AndroidMakers Paris
prof18
0
170
AWS CDKコントリビュートTIPS / aws-cdk-contribution-tips
gotok365
4
550
VS Code をプロダクトにどう取り込むか
onomax
1
780
Ruby on Fails - effective error handling with Rails conventions
talyssonoc
0
210
if constexpr文はテンプレート世界のラムダ式である
faithandbrave
3
710
Tailwind CSSを本気でカスタマイズする方法
fsubal
15
5.6k
Ruby Function Composition
bkuhlmann
1
340
CREってこういうこと? 体験入社 - 提案資料 - / what-is-cre-trial-employment
shinden
1
580
Domain-Driven Transformation
hschwentner
2
1.5k
Featured
See All Featured
Automating Front-end Workflow
addyosmani
1357
200k
How to Ace a Technical Interview
jacobian
273
22k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
34
8.9k
Done Done
chrislema
178
15k
Build The Right Thing And Hit Your Dates
maggiecrowley
25
2k
Large-scale JavaScript Application Architecture
addyosmani
504
110k
Six Lessons from altMBA
skipperchong
22
3k
Testing 201, or: Great Expectations
jmmastey
30
6.4k
How to name files
jennybc
65
93k
Intergalactic Javascript Robots from Outer Space
tanoku
266
26k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
66
14k
Designing the Hi-DPI Web
ddemaree
276
33k
Transcript
PROGRESSIVE WEB APPS Oscar Cortez Dec 2018
¿QUE ES UNA PWA?
UN MOMENTO
PWA
APWA
AWPW
AMWP
AMP
AMP != PWA
None
KILLEDBYGOOGLE.COM
None
RECAPITULANDO
¿QUE ES UNA PWA?
LAS PROGRESSIVE WEB APPS SON EXPERIENCIAS QUE COMBINAN LO MEJOR
DE LA WEB Y LO MEJOR DE LAS APPS. Pete LePage PWA
None
UN SITIO QUE USA LAS TECNOLOGÍAS MODERNAS EN LOS NAVEGADORES
Y LAS MEJORES PRACTICAS PARA PROVEER UNA EXPERIENCIA RÁPIDA Y NATIVA. Zack Argyle PWA
UN SITIO QUE USA LAS TECNOLOGÍAS MODERNAS EN LOS NAVEGADORES
Y LAS MEJORES PRACTICAS PARA PROVEER UNA EXPERIENCIA RÁPIDA Y NATIVA. Zack Argyle PWA
DE CONFIANZA RAPIDAS ATRACTIVAS PWA es…
TECNOLOGIAS USADAS
•HTTPS •W3C MANIFEST •SERVICE WORKER •CACHE
HTTPS
¯\_(ツ)_/¯
W3C MANIFEST
{ "name": "Donate App", "description": "This app helps you donate
to worthy causes.", "icons": [{ "src": "images/icon.png", "sizes": "192x192" }] }
<!DOCTYPE html> <html> <head> <title>Racer 3K</title> <!-- Startup configuration -->
<link rel="manifest" href="manifest.webmanifest"> <!-- Fallback application metadata for legacy browsers --> <meta name="application-name" content="Racer3K"> <link rel="icon" sizes="16x16 32x32 48x48" href="lo_def.ico"> <link rel="icon" sizes="512x512" href="hi_def.png"> </head> <body> </body> </html>
SERVICE WORKERS
UN SERVICE WORKER ES UNA SECUENCIA DE COMANDOS QUE TU
NAVEGADOR EJECUTA EN SEGUNDO PLANO, SEPARADO DE UNA PÁGINA WEB. Matt Gaunt SW
if ('serviceWorker' in navigator) { window.addEventListener('load', function() { navigator.serviceWorker.register('/sw.js') .then(function(registration)
{ // Registration was successful console.log('ServiceWorker registration successful'); console.log('with scope: ', registration.scope); }).catch(function(err) { // registration failed :( console.log('ServiceWorker registration failed: ', err); }); }); }
CACHE
SÓLO HAY DOS COSAS DURAS EN CIENCIAS DE LA COMPUTACIÓN:
INVALIDAR UNA MEMORIA CACHÉ Y NOMBRAR LAS COSAS. Confusio :p CACHE
•CACHE ONLY •NETWORK ONLY •CACHE FALLING TO NETWORK OR VICE
VERSA •CACHE & NETWORK RACE •CACHE THEN NETWORK •GENERIC FALLBACK •YOUR CUSTOM WAY :P
COMO SE VE UNA PWA
POKEDEX.ORG
LAS 3R’S PARA INCREÍBLES PWA’S
REDUCE REUSE REVIEW
REDUCE REUSE REVIEW
A MEDIDA QUE CONSTRUIMOS SITIOS QUE DEPENDEN CADA VEZ MÁS
DE JAVASCRIPT, A VECES PAGAMOS POR LO QUE ENVIAMOS DE MANERAS QUE NO SIEMPRE VEMOS FÁCILMENTE. Addy Osmani REDUCE
REDUCE REUSE REVIEW
REUSE Service Worker Network Website Cache
REDUCE REUSE REVIEW
INDEPENDIENTEMENTE DE LAS HERRAMIENTAS QUE ELIJA SU EQUIPO, UN PRESUPUESTO
ES ESENCIAL. SIN UNO, INCLUSO LOS MÁS AVANZADOS, Y “LIGEROS" FRAMEWORKS PUEDEN CREAR FÁCILMENTE APLICACIONES INFLADAS E INUTILIZABLES. Alex Russel REVIEW
NO EXISTEN SITUACIONES HIPOTETICAS
LA FUERZA USAR DEBES
None
•APP-Shell: La arquitectura que usaras. •Browser Dev Tools: Tu navaja
suiza. •IndexedDB: Almacenamiento estructurado de datos. •WorkBox: Set de librerias para PWAs.
•Lighthouse: Auditar nuestras PWAs. •Google PWA Checklist: Lo que tienes
que considerar. •SSR: Compilar tu HTML en el servidor. •SW-Precache: Generador de Service-Workers.
None
=> RTFM <= HTTPS://WEB.DEV
GRACIAS POR SU ATENCIÓN! @oscar_mcm