Open yzqdev opened 5 months ago
when set optimization: { minimize: true}, all metadata will lost https://github.com/trim21/userscript-metadata-webpack-plugin/blob/5916ecb7322ca46358c4aba6c7892f7fdedede24/src/index.ts#L36-L39
optimization: { minimize: true},
https://webpack.js.org/api/compilation-hooks/#list-of-asset-processing-stages
we could inject metadata at PROCESS_ASSETS_STAGE_SUMMARIZE stage,this is after optimize process
PROCESS_ASSETS_STAGE_SUMMARIZE
would you mind show a full webpack config?
this the repo , dist contains optimized js and non-optimized js
https://github.com/yzqbugs/meta-bug
Description
when set
optimization: { minimize: true},
all metadata will lost https://github.com/trim21/userscript-metadata-webpack-plugin/blob/5916ecb7322ca46358c4aba6c7892f7fdedede24/src/index.ts#L36-L39https://webpack.js.org/api/compilation-hooks/#list-of-asset-processing-stages
we could inject metadata at
PROCESS_ASSETS_STAGE_SUMMARIZE
stage,this is after optimize process