vbenjs / vite-plugin-compression

Use gzip or brotli to compress resources
MIT License
404 stars 31 forks source link

index.html not referencing the new gzipped files #21

Open andywillis opened 2 years ago

andywillis commented 2 years ago

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.

ffind commented 2 years ago

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