Questions tagged [background-sync]

61 questions
0
votes
1 answer

Workbox Background Sync - Redirect After User Submits Form

Users can submit a form when offline that gets synced to my database with background sync. This is working as expected. The issue I am having is that when the user is offline and submits the form it redirects to a "site not found" error page in…
0
votes
1 answer

Workbox background sync not storing in mysql database

I can get the sync to work and clear out the IndexedDB queue but the data is not being stored in my mysql database. Is there something I am missing? My service…
doobe01
  • 1
  • 2
0
votes
1 answer

Pwa Workbox Sync-background UI

BackgroundSync, from workbox, works perfectly but I have a problem I want that when I modify an element, even if the request is still in indexedDB, the element is not updated on my pwa (UI), when I am offline. For now, when I change the element ( in…
0
votes
1 answer

javascript background sync android power button

service worker sync will not fire on case in android chrome WHAT IM MISSING ??? Same thing in here: JavaScript Background Sync Stops Working if Page is Loaded/Refreshed while offline unplug usb cable for development (for chrome dev tool) push…
0
votes
1 answer

Workbox 5.1.2 backgroundSync Queue configuration

I have recently migrated from Workbox 3.5.0 to Workbox 5.1.2 I am using Workbox SW via CDN importScripts('https://storage.googleapis.com/workbox-cdn/releases/5.1.2/workbox-sw.js'); I have updated my service worker file to use the latest Plugin…
edwardinchains
  • 119
  • 1
  • 12
0
votes
1 answer

How to verify if background sync is supported by the browser?

I am developing an application that uses service workers to cache HTTP requests from a specific endpoint. These requests should be sent to the server using background sync. I know some browsers are not supported, but I would like to warn my users…
0
votes
1 answer

Background sync doesn't refresh page when back online

recently I started learning about service workers, background syncs... I implemented service worker and in install step I cached some files I want to show when offline. self.addEventListener('install', (event) => { event.waitUntil( …
olga_babic
  • 1,600
  • 3
  • 9
  • 18
0
votes
1 answer

how to configure runtimeCaching for POST operations in workbox-config.js

I am doing background queue configuration in workbox for "POST" operation. Kindly guide me where to give option for "POST" operation inside 'runtimeCaching' configuration in workbox-config.js module.exports = { "globDirectory": "dist/", …
0
votes
0 answers

How does StackExchange deliver changes to pages if background sync if off?

I happen to keep background sync on my browser off yet, the changes that occur to a page on StackOverflow appear on the page on the top like it usually used to, you know the "An edit has been made to this post" banner at the top. (Edited) That made…
user79161
  • 291
  • 2
  • 14
0
votes
1 answer

Workbox Background Sync not Working on Mobile

UPDATE: Turns out it was working, I just needed to manually restart the service worker for the requests to be fired again. On-going issue in another post. I have an application front end written in angular, intended to be used on iPads located…
Keithers
  • 354
  • 6
  • 23
0
votes
1 answer

How to retrieve JSON object stored in cache from service worker?

I have a Json object stored in cache , Please see my cache here. And I want to retrieve the json values from my service worker caches.open('my-post-request').then(function (cache) { cache.match('/cached-products.json').then(function…
0
votes
2 answers

Background Sync codes not working automatically when online(wifi on) in PWA

I am new to PWA and have been testing my PWA project using firebase console database. When offline, I have code to save my post data in indexedDB when i submit my post data to saved later when there is WiFi(online). It did save the data in indexedDB…
0
votes
1 answer

Service Worker: handle requests when offline to send them when online

I have a chat web application and I want it to work offline. For this I use progressive web apps features (Service Workers) to use cache to get the shell app and the messages already loaded. What I want to do is to be able to make a post message…
guts
  • 381
  • 1
  • 9
  • 22
0
votes
1 answer

How to queue post request using workbox?

Using following js in my service worker from workboxjs sample for my testing: importScripts('https://unpkg.com/workbox-sw@0.0.2/build/importScripts/workbox-sw.dev.v0.0.2.js'); I want to try out how to queue the post requests in offline mode using…
seUser
  • 1,093
  • 2
  • 10
  • 21
0
votes
1 answer

Setup of ember-service-worker-cache-fallback to sync data

I'm a beginner in ember and service workers. My goal is to setup a simple ember app that works offline. I basically have a list of elements that are available through an API (GET/POST). When I'm online, everything works as expected. I can GET the…
burni
  • 1
  • 1