GithubHelp home page GithubHelp logo

Comments (11)

Zavim avatar Zavim commented on July 18, 2024

I had this same issue. I was able to solve it by removing the site from my history (in my case it was just localhost -- http://127.0.0.1:3000/). There should be something like "remove this site from my history" in the History settings of your browser.

from docs.

userquin avatar userquin commented on July 18, 2024

@matthew-dean @Zavim have you read the docs? You MUST not change anything in the configuration, just add selfDestroying: true, check the DANGER entry: https://vite-pwa-org.netlify.app/guide/unregister-service-worker.html

from docs.

Zavim avatar Zavim commented on July 18, 2024

I hadn't changed anything in the configuration, just removed localhost:3000 from my browser history. Either way, my case was a practice PWA, not client-facing.

from docs.

Yankovsky avatar Yankovsky commented on July 18, 2024

I have the same issue and I didn't change anything in the config.

from docs.

Yankovsky avatar Yankovsky commented on July 18, 2024

I think of adding a script to GTM to unregister a service worker, bust the cache and refresh the page for the user. Super hacky and ugly, but I am out of options.

from docs.

Yankovsky avatar Yankovsky commented on July 18, 2024

I am also trying to play with downgrading vite-plugin-pwa version, because I have a feeling that something was added to the config on the plugin side, and because of that service workers names or something else don't match.

from docs.

userquin avatar userquin commented on July 18, 2024

We haven't change anything about the sw name, check it in local without selfDestroying and then add it again, maybe you have some old tests on your local.

Ensure your original sw precache manifest doesn't include the sw itself.

imagen

from docs.

Yankovsky avatar Yankovsky commented on July 18, 2024

Downgrading from ^0.16.4 to 0.12.8 helped. It worked!

from docs.

userquin avatar userquin commented on July 18, 2024

uhmm, I'll check changes between those versions, are you using injectManifest strategy?

from docs.

Yankovsky avatar Yankovsky commented on July 18, 2024

Yes, I have the following config:

VitePWA({
        strategies: 'injectManifest',
        registerType: 'autoUpdate',
        injectManifest: {
          maximumFileSizeToCacheInBytes: 5_000_000,
        },
        selfDestroying: true,
      }),

Look, maybe it was something else, I didn't do a thorough investigation.

from docs.

Yankovsky avatar Yankovsky commented on July 18, 2024

I had version 0.11.13 installed. Then I updated to the latest version of the plugin and added the flag. It didn't work (or maybe I did something incorrectly). Then I downgraded to 0.12.8 and it worked.

from docs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.