Closed ntltd closed 1 year ago
umm. Because you don't set threshold
so the plugin will consume all chunk
as i can know. manualChunks
also be consume in the full process. Have you generated the corresponding gz file locally?
Not sure if threshold
has to be set because I don't want to filter files by size.
If I disable deleteOriginalAssets
, gz files of my chunks are generated. When I enable the option, they are delete at build.
I mean you turned deleteOriginalAssets
on to generate lodash.js.gz
?
If I use the compress()
plugin with deleteOriginalAssets
turned off, it generates lodash.js.gz
along lodash.js
file:
But if I turn on the option, the files are not generated anymore, the chunk seems to not be taken in account anymore.
jesus, i set the same option in my local but it can work well. I'm not sure what happened in your local :( . I think if you can provide a minimum repo is well.
By the way. the logo info is unreliable. When the chunk has side effect. It won't print out in your terminal. You should view the generated
Yep, I tried to create a new repository with the same config, but it seems to work indeed: https://github.com/ntltd/vite-plugin-compression I'm trying to figure out what's happening on the other repository 🤔
Ok got it! It's not the same order on the prompt when I use the deleteOriginalAssets
option but compressed files are here 🙈
Really sorry for disturbing and thanks for your amazing work!
Bug report 🐞
With this build config, the plugin seems to remove chunking strategy when using
deleteOriginalAssets
option:Do you have an idea why? Thanks
Version & Environment
Expectation
Manual chunks should be generated:
Actual results (or Errors)
Manual chunks are not generated anymore: