humm. Hard to know without seeing your site. It seems there is a syntax error in the service worker that is causing it to fail to install. What is the URL of your service worker?
Hello @westonruter
Thank you for your support.
I would also like to mention one more problem.
again similarly related to the multi language feature.
the default language of my website is English. but strangely the PWA feature (browser alert) is not activated when in english language.
However, when a different language is selected, the PWA warning and loading quickly occurs on both mobile devices and the computer browser 🙂
please review this when you review the previous issue.
[ Short link removed ]
(I wanted to add it as an abbreviation so as not to share my URL explicitly.)
-
This reply was modified 1 year, 11 months ago by
aga2442.
-
This reply was modified 1 year, 11 months ago by
Jan Dembowski.
Moderator
Jan Dembowski
(@jdembowski)
Forum Moderator and Brute Squad
@aga2442 Do not use short links in these forums, that has been abused in the past and is expanded when found. I have expanded yours into the link field.
The link field cannot be seen any search engines. Normally the link is expanded when found but I expanded it into the hidden from search engines link field.
Hello @westonruter
Thank you for your support.
I would also like to mention one more problem.
again similarly related to the multi language feature.
the default language of my website is English. but strangely the PWA feature (browser alert) is not activated when in english language.
However, when a different language is selected, the PWA warning and loading quickly occurs on both mobile devices and the computer browser 🙂
please review this when you review the previous issue.
[ redundant link removed ]
I’m looking at the service worker code and it seems that the translation plugin is corrupting the JavaScript. For example, in the JS file:
const offlinePostRequestHandler = ({ event }) => {
return fetch(event.request)
.then((response) => {
if (response.status < 500) {
return response;
}
// @todo This is duplicated with code in service-worker-navigation-routing.js.
return response.text().then(function (errorText) {
This is getting turned into the following in the French version:
const offlinePostRequestHandler = ({ event }) => {
return fetch(event.request)
.then((response) => {
if (response.status < 500) { réponse de retour ; } // @todo Ceci est dupliqué avec le code dans service-worker-navigation-routing.js. return réponse.text().then(function (errorText) ...
So the translation logic is erroneously attempting to translate the JavaScript code.
So I think this is something you should raise with the plugin author, or if you can perhaps find a way to prevent translation for URLs that end in wp.serviceworker.