-
Notifications
You must be signed in to change notification settings - Fork 6
[Bug] PWA template fails in lighthouse PWA audit #6
Comments
Lighthouse report needs to be run on a production build (on a server to get 100 on each category), not on a dev build. |
@rstoenescu The result I got is tested with |
The steps taken with a fresh app.
Then proceeded to serve the content within Removing the config line mentioned and repeating |
I can not confirm this error, I set up two versions of the PWA template, one with the default config and one with the nginx config:
Also on the Github directory for sw-precache staticfileglobs it says
So for me it doesn't look like a good idea to remove the line?! |
We should also be referencing the README from https://github.com/goldhand/sw-precache-webpack-plugin#configuration
|
I believe my problem with the Chrome Audit (PWA - lighthouse) stems from the config Looking around the web, it seems that https://www.polymer-project.org/2.0/toolbox/service-worker |
Pushed json along with some more extensions to the template. Glad it works now, although it's pretty peculiar why for some it works and for some it didn't. |
Lighthouse fails with
The problem lies with the configuration of
sw-precache-webpack-plugin
. Simply remove the line containingstaticFileGlobs
to make the precaching work for all emitted files rather than just forjs,html,css,woff,svg
solves the problem.Out of the box, most of the time we would want the precaching to cache all assets for the PWA to work offline. Removing the
staticFileGlobs
line will achieve that.quasar-template-pwa/template/build/webpack.prod.conf.js
Line 94 in 481bdb5
The text was updated successfully, but these errors were encountered: