I am using the Angular-CLI 1.6.6 and @angular/service-worker 5.2.5 in our Angular 5.2.5 app. Everything works fine on the local lite-server, as well as on the production server, except for one error message popping in our production environment:…
I have an Angular PWA. Its service worker was working flawlessly until I upgraded from Angular 5.0 to 7.2
After the upgrade, I see the following error in /ngsw/state
Driver state: SAFE_MODE (Initialization failed due to error: Invariant violated…
In previous versions of the Angular service worker implementation, one of the config options was "routing". This can be seen in this unanswered SO question, was referenced in this Angular CLI issue, and the best remaining documentation seems to be…
I am getting the following error
ERROR Error: Uncaught (in promise): TypeError: Failed to register a ServiceWorker: A bad HTTP response code (404) was received when fetching the script.
TypeError: Failed to register a ServiceWorker: A bad HTTP…
I am struggling to make my Server Side Rendering and Service Worker cooperate on server Side.
Information regarding localhost -> Working
This is working as expected. The service worker works and updates my app on every update. Moreover; a curl…
I'm trying to add service workers to our existing angular (5.2, CLI 1.7.1) application. I did everything I was suppose to:
I created ngsw-config.json
I run the the ng set apps.0.serviceWorker=true command so I have "serviceWorker": true, in…
I have an angular app and as soon as I add a serviceWorker following these steps:
https://github.com/angular/angular-cli/blob/master/docs/documentation/build.md#service-worker
https://angular.io/guide/service-worker-getting-started
…my API requests…
While there are similar posts, I can't find clear answer if index.html should be cached using Cache-Control header.
Correct me if I am wrong, but right now I am returning Cache-Control: no-store for index.html to avoid hash mismatch errors which…
I have an Angular application (version 7.2.2) using the Angular Service Worker (version 7.2.12).
The service worker intermittently serves an old version of the application. On refresh the new version is shown, but if the user closes and reopens the…
I would like to know if it' s possible to test pwa and register the serviceworker during the dev mode ( not production)
As when i make the ng build --prod then launchhttp-server in the dist folder it works fine, but then when i do ng serve without…
I am following angular's best practice in order to make PWA.
After making production build (ng build --prod --aot), I am also running the service worker from dist, on localhost:
http-server -p 8080 -c-1 dist
When I am trying to sync the worker…
I am trying to use push notification in a pwa, but it is failing to receive the notification.
On the client side I am receiving the following error
Uncaught SyntaxError: Unexpected token P in JSON at position 0
at Driver.onPush…
it seems that angular6 does not support background syncing with service worker. What are the steps required to do this without any library in an angular service?
https://developers.google.com/web/updates/2015/12/background-sync
How and where can I…
Everytime I make any change to the index.html with my Angular project, Service Worker never gets updated and always serves the old cached version on index.html. How do I fix this (Also, there is no caching at the server end as well as browser)
Here…