File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ contributors:
55 - simon04
66 - byzyk
77 - chenxsan
8+ - snitin315
89related :
910 - title : banner-plugin-hashing test
1011 url : https://github.com/webpack/webpack/blob/main/test/configCases/plugins/banner-plugin-hashing/webpack.config.js
@@ -31,6 +32,7 @@ new webpack.BannerPlugin(options);
3132 include: string | RegExp | [string, RegExp], // Include all modules matching any of these conditions.
3233 exclude: string | RegExp | [string, RegExp], // Exclude all modules matching any of these conditions.
3334 footer?: boolean, // if true, the banner will be placed at the end of the compilation
35+ stage?: number, // the stage of the compilation in which the banner should be injected
3436}
3537` ` `
3638
@@ -50,6 +52,13 @@ new webpack.BannerPlugin({
5052 return ` yourVariable: ${yourVariable } ` ;
5153 },
5254});
55+
56+ // It will add the banner message after minimizers and any asset manipulation
57+ new webpack .BannerPlugin ({
58+ raw: true ,
59+ banner: ' /* banner is a string */' ,
60+ stage: webpack .Compilation .PROCESS_ASSETS_STAGE_REPORT ,
61+ });
5362` ` `
5463
5564## Placeholders
You can’t perform that action at this time.
0 commit comments