-
Notifications
You must be signed in to change notification settings - Fork 858
Closed
Labels
Description
Library Affected:
workbox-webpack-plugin
I'm filing this bug as a reminder to address a few takeaways after integrating the 3.0.0-alpha.2 version of new WorkboxPlugin() (without any config) into a vue init webpack-scaffolded project.
The manifest it generates looks like:
self.__precacheManifest = [
{
"url": "/static/js/vendor.838a79d42f288249609f.js.map"
},
{
"url": "/static/js/vendor.838a79d42f288249609f.js"
},
{
"url": "/static/js/manifest.b7d5cdcec7f9d47fa7ac.js.map"
},
{
"url": "/static/js/manifest.b7d5cdcec7f9d47fa7ac.js"
},
{
"url": "/static/js/app.f3ffa612454f0757334d.js.map"
},
{
"url": "/static/js/app.f3ffa612454f0757334d.js"
},
{
"revision": "e8d1748dd5e87a88a36cedc37d531728",
"url": "/static/css/app.bf9a994c72151daa5e919b0f3ccdc900.css.map"
},
{
"revision": "f3ffa612454f0757334d",
"url": "/static/css/app.bf9a994c72151daa5e919b0f3ccdc900.css"
},
{
"revision": "ba37e5362c2060a35dd4625a0093eb3d",
"url": "/index.html"
}
];There are a few takeaways to follow up on. Some of which may already be tracked independently.
- We need to omit the
.mapfiles by default. - We need to omit the webpack-specific
manifest.[hash].jsby default. We need to use relative, rather than absolute, URLs.(EDIT: This is due topublicPathbeing configured as/, and we should continue usingpublicPath, so there's nothing to change.)- We need to detect that the CSS file already includes a hash (it's produced via
ExtractTextPlugin()being fed intoOptimizeCSSPlugin()).