vite-plugin-compression icon indicating copy to clipboard operation
vite-plugin-compression copied to clipboard

index.html not referencing the new gzipped files

Open andywillis opened this issue 3 years ago • 1 comments
trafficstars

With vite-plugin-compress index.html does not need to be updated because the names of compressed files are don't change, and so the links in index.html do not need to be changed.

But gzipping the files means that new files are created, and the links to the new files need to be corrected in index.html.

andywillis avatar Jul 03 '22 14:07 andywillis

Hi @andywillis index.html should not point to gzip files. Handling compressed files should be done by server. For express use express-static-gzip

ffind avatar Aug 02 '22 19:08 ffind