service-worker


Service worker's offline caching is not working if I add my PWA on home screen


I made a PWA. Currently is deployed on heroku. URL - https://plain-js-pwa.herokuapp.com/.
My PWA installs service worker and manifest.json file. If I open it on chrome on mobile phone and put my phone on flight mode, then refreshing the url still gives shows me my application. Its expected as my service worker is doing offline caching.
But when I add my PWA to home screen, and try to open it on flight mode then it doesn't work. This is probably my first PWA, so please help me. I am generating my service worker file from 'sw-precache-webpack-plugin'.
My manifest.json file is:
{
"name": "VanillaJS-webpack App",
"short_name": "VanillaJS-webpack App",
"description": null,
"dir": "auto",
"lang": "en-US",
"display": "standalone",
"orientation": "any",
"start_url": "/?homescreen=1",
"background_color": "#ee6e73",
"icons": [
{
"src": "android-chrome-36x36.png",
"sizes": "36x36",
"type": "image/png"
},
{
"src": "android-chrome-48x48.png",
"sizes": "48x48",
"type": "image/png"
},
{
"src": "android-chrome-72x72.png",
"sizes": "72x72",
"type": "image/png"
},
{
"src": "android-chrome-96x96.png",
"sizes": "96x96",
"type": "image/png"
},
{
"src": "android-chrome-144x144.png",
"sizes": "144x144",
"type": "image/png"
},
{
"src": "android-chrome-192x192.png",
"sizes": "192x192",
"type": "image/png"
},
{
"src": "/android-chrome-256x256.png",
"sizes": "256x256",
"type": "image/png"
},
{
"src": "/android-chrome-384x384.png",
"sizes": "384x384",
"type": "image/png"
},
{
"src": "/android-chrome-512x512.png",
"sizes": "512x512",
"type": "image/png"
}
]
}

Related Links

Use Service Worker to intercept requests on the first load of my site?
service worker showNotification require interaction flag
How to remotely dismiss notifications using web push notifications?
DOMException: Failed to register a ServiceWorker: ServiceWorker script evaluation failed
UpUp to force the offline.html even when online
event.waitUntil throws an error when called in a push event listener
Ignore ajax requests in service worker
How to de-duplicate notifications between native and progressive web app?
Is it possible to use the new Push Notifications support in Chrome without GCM?
How to get registration id in push event in ServiceWorker?
Service Worker and transparent cache updates
Service-worker force update of new assets
Hosting service-worker file from CDN/Google Drive
How to use Google Analytics in Progressive Web Apps that may be offline?
Will Service Worker Query Cache Algorithm Allow Expression Matching URL paths?
How is the Push API's push service URL set?

Categories

HOME
assembly
scikit-learn
hyperlink
merge
c99
amp-html
css3
youtube-data-api-v3
themes
rendering
pdfbox
carousel
spring-session
reactive-programming
fhir
pega
text-mining
do-while
altera
modbus-tcp
atlassian-stash
intershop
google-content-api
nim
blade
spring-async
joptionpane
epsilon
ckfinder
apktool
8051
inversion-of-control
testcomplete
mockjax
quickfixj
playstation-portable
sendbird
vue-chartjs
dynamic-jasper
reverse
watchman
imagenet
release
amazon-ses
apns-php
cin
mongoose-schema
jvmti
opensmpp
skylink
ssrs-2014
placeholder
getchar
mschart
vugen
convex-optimization
subnet
er-diagram
baidu
renaming
testrail
hadoop-2.7.2
centrifuge
delta
android-dateutils
jclouds
clipboard.js
php-socket
grass
sapi
computer-architecture
jdi
vacuum
liquid-layout
ansi
aspectj-maven-plugin
umlgraph
xmltype
public-html
exceldatareader
dbaccess
execve
structuremap3
human-computer-interface
lambda-architecture
codeplex
xmltodict
mt4j
visual-studio-express
ie8-compatibility-mode
inputmismatchexception
modular
unit-of-work
nebula
node-blade
mkv
rmiregistry
subproject
jquery-tools
xui
ruby-1.8
metaweblog
facebook-iframe
mathematical-notation
alsb
entitykey

Resources

Encrypt Message



code
soft
python
ios
c
html
jquery
cloud
mobile