File tree 2 files changed +17
-11
lines changed
2 files changed +17
-11
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,8 @@ module.exports = {
50
50
// Options similar to the same options in webpackOptions.output
51
51
// both options are optional
52
52
filename: " [name].css" ,
53
- chunkFilename: " [id].css"
53
+ chunkFilename: " [id].css" ,
54
+ orderWarning: true // Disable to remove warnings about conflicting order
54
55
})
55
56
],
56
57
module: {
Original file line number Diff line number Diff line change @@ -113,6 +113,7 @@ class MiniCssExtractPlugin {
113
113
this . options = Object . assign (
114
114
{
115
115
filename : '[name].css' ,
116
+ orderWarning : true ,
116
117
} ,
117
118
options
118
119
) ;
@@ -480,16 +481,20 @@ class MiniCssExtractPlugin {
480
481
// use list with fewest failed deps
481
482
// and emit a warning
482
483
const fallbackModule = bestMatch . pop ( ) ;
483
- compilation . warnings . push (
484
- new Error (
485
- `chunk ${ chunk . name || chunk . id } [mini-css-extract-plugin]\n` +
486
- 'Conflicting order between:\n' +
487
- ` * ${ fallbackModule . readableIdentifier ( requestShortener ) } \n` +
488
- `${ bestMatchDeps
489
- . map ( ( m ) => ` * ${ m . readableIdentifier ( requestShortener ) } ` )
490
- . join ( '\n' ) } `
491
- )
492
- ) ;
484
+ if ( this . options . orderWarning ) {
485
+ compilation . warnings . push (
486
+ new Error (
487
+ `chunk ${ chunk . name || chunk . id } [mini-css-extract-plugin]\n` +
488
+ 'Conflicting order between:\n' +
489
+ ` * ${ fallbackModule . readableIdentifier (
490
+ requestShortener
491
+ ) } \n` +
492
+ `${ bestMatchDeps
493
+ . map ( ( m ) => ` * ${ m . readableIdentifier ( requestShortener ) } ` )
494
+ . join ( '\n' ) } `
495
+ )
496
+ ) ;
497
+ }
493
498
usedModules . add ( fallbackModule ) ;
494
499
}
495
500
}
You can’t perform that action at this time.
0 commit comments