You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are using CompressionPlugin as the last step of our webpack config. When specifying deleteOriginalAssets: true it does remove original .js file when .js.gz is produced, but it also accidentally deletes accompanying .js.LICENSE.txt
Actual Behavior
With deleteOriginalAssets: false:
-rw-r--r-- 1 mman staff 1423307 May 21 11:42 60.96569f9e.js
-rw-r--r-- 1 mman staff 2881 May 21 11:42 60.96569f9e.js.LICENSE.txt
-rw-r--r-- 1 mman staff 421274 May 21 11:42 60.96569f9e.js.gz
-rw-r--r-- 1 mman staff 160371 May 21 11:42 main.c742e74d.js
-rw-r--r-- 1 mman staff 1818 May 21 11:42 runtime-main.17566f78.js
With deleteOriginalAssets: true:
-rw-r--r-- 1 mman staff 421274 May 21 11:42 60.96569f9e.js.gz
-rw-r--r-- 1 mman staff 160371 May 21 11:42 main.c742e74d.js
-rw-r--r-- 1 mman staff 1818 May 21 11:42 runtime-main.17566f78.js
You can write a custom function for this option deleteOriginalAssets, i.e. return false for such files, but I agree we should not delete LICENSE files here
Bug report
We are using
CompressionPlugin
as the last step of our webpack config. When specifyingdeleteOriginalAssets: true
it does remove original.js
file when.js.gz
is produced, but it also accidentally deletes accompanying.js.LICENSE.txt
Actual Behavior
With
deleteOriginalAssets: false
:With
deleteOriginalAssets: true
:Expected Behavior
.js.LICENSE.txt
should remain in place.How Do We Reproduce?
This bug is affecting the following project where I summarised the issue as victronenergy/venus-html5-app#370.
Main webpack config is located here: https://github.com/victronenergy/venus-html5-app/blob/master/config/webpack.config.js
Please paste the results of
npx webpack-cli info
here, and mention other relevant informationThe text was updated successfully, but these errors were encountered: