File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed
test/cases/filename-function Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -268,7 +268,9 @@ class MiniCssExtractPlugin {
268268 if ( Object . keys ( chunkMap ) . length > 0 ) {
269269 const chunkMaps = chunk . getChunkMaps ( ) ;
270270 const linkHrefPath = mainTemplate . getAssetPath (
271- JSON . stringify ( this . options . chunkFilename ) ,
271+ JSON . stringify (
272+ this . getFilename ( chunk , this . options . chunkFilename )
273+ ) ,
272274 {
273275 hash : `" + ${ mainTemplate . renderCurrentHashCode ( hash ) } + "` ,
274276 hashWithLength : ( length ) =>
Original file line number Diff line number Diff line change @@ -18,8 +18,8 @@ module.exports = {
1818 } ,
1919 plugins : [
2020 new Self ( {
21- filename : ( chunk ) => chunk == 'app' ? 'this.is.app.css' : ' [name].css' ,
22- chunkFilename : ( chunk ) => '[name].css' ,
21+ filename : ( data ) => data . chunk . name == 'app' ? 'this.is.app.css' : ` [name].css` ,
22+ chunkFilename : ( data ) => '[name].css' ,
2323 } ) ,
2424 ] ,
2525} ;
You can’t perform that action at this time.
0 commit comments