File tree Expand file tree Collapse file tree
test/configCases/split-chunks/intersections-min-size Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -348,7 +348,7 @@ const ALL_CHUNK_FILTER = (_chunk) => true;
348348/** Placeholder until a chunk set group is filled and its signatures are written. */
349349const EMPTY_SIGNATURES = new Uint32Array ( 0 ) ;
350350
351- const MIN_INTERSECTION_CHUNKS = 2 ;
351+ const MIN_INTERSECTION_CHUNKS = 1 ;
352352const MAX_INTERSECTION_CANDIDATE_FACTOR = 2 ;
353353const MAX_INTERSECTION_CANDIDATES = 4096 ;
354354const MAX_INTERSECTION_PAIRS = 500000 ;
Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ const config = ({
4141 target : "node" ,
4242 entry : {
4343 a : "./a" ,
44- b : "./b" ,
44+ ... ( minChunks === 1 ? { } : { b : "./b" } ) ,
4545 ...( higherOrder
4646 ? { c : "./pair01" , d : "./pair02" , e : "./pair12" }
4747 : { c : "./c0" , d : "./c1" , e : "./c2" } )
@@ -80,7 +80,7 @@ const config = ({
8080 ( compiler ) => {
8181 compiler . hooks . done . tap ( "AssertIntersectionCandidates" , ( stats ) => {
8282 const { chunkGraph, modules } = stats . compilation ;
83- const shouldSplit = ! belowThreshold && minChunks == = 2 ;
83+ const shouldSplit = ! belowThreshold && minChunks < = 2 ;
8484 const shared = [ ...modules ] . filter ( ( module ) => {
8585 const name = module . nameForCondition ( ) ;
8686 return name !== null && / [ \\ / ] m [ 0 1 2 ] \. j s $ / . test ( name ) ;
@@ -114,5 +114,6 @@ module.exports = [
114114 { usedExports : true , higherOrder : true } ,
115115 { named : true } ,
116116 { reductionOnly : true } ,
117+ { minChunks : 1 } ,
117118 { minChunks : 3 }
118119] . map ( config ) ;
You can’t perform that action at this time.
0 commit comments