Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optional section is not cached correctly #475

Open
johanarnor opened this issue Jan 29, 2020 · 0 comments
Open

Optional section is not cached correctly #475

johanarnor opened this issue Jan 29, 2020 · 0 comments

Comments

@johanarnor
Copy link

Hi! I've an issue where assets in the optional section are not present in the cache after a new build. The caches option is configured (heavily simplified) like this:

caches: {
  main: ['index.html', 'app.js'],
  optional: ['app.css']
},

Steps to reproduce:

  • Load the site and see that all 3 assets are cached.
  • Make a new build (ensure that app.css is unchanged) and apply the update. Only index.html and app.js are now present in the cache.
  • Go offline and reload the site - app.css is not loaded since it's not in the cache.

Is it possible to "transfer" the previously cached version of app.css to the new cache, since the hash is same? Or is there some reason that it doesn't work as I thought it would? Or maybe I've just messed up my config somehow...

Any help would be much appreciated!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant