Quasar build - file timestamps
-
After running Quasar build, all the files in the “dist” folder have new timestamps on them. Is there any way to tell the builder to retain the original file’s timestamp?
If I have a static image that doesn’t change, it should not have a new timestamp every time the project is built!
-
There’s currently no way to avoid this other than manually uploading and not overriding /statics folder. The statics folder gets copied over to dist on each build. Will think of a way to only copy it if something indeed changed in the statics folder.
-
-
This is especially a problem with the “vendor.js” file. When I make a small tweak to some wording in my site, the user has to re-download this massive file, even though it did not change at all!
-
@glittle That’s why there’s a manifest.js file getting created there. That won’t change
It’s part of the smart code-splitting strategy I wrote in the default Quasar template.
-
I’m using the constant ‘watch’ based build which do not changes unneeded files.
…package.json…
scripts: {
“watch”: “WATCH=true node build/script.build.js”,
…
…build/webpack.prod.conf.js…
var watching = process.env.WATCH;var webpackConfig = merge(baseWebpackConfig, {
watch: watching ? true : false,
…and launch ‘npm run watch’ process. So any new file upload will initiate the incremental build. So such build is faster because of this.