Skip to content

Commit 140af52

Browse files
authored
hotfix: module graph lack modules (#1403)
1 parent aaa31cf commit 140af52

File tree

1 file changed

+14
-11
lines changed

1 file changed

+14
-11
lines changed

packages/core/src/inner-plugins/plugins/ensureModulesChunkGraph.ts

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -124,17 +124,20 @@ async function doneHandler(
124124
let cached: Plugin.StatsCompilation | null = null;
125125
return () => {
126126
if (cached) return cached as Plugin.StatsCompilation;
127-
cached = stats.toJson({
128-
all: false,
129-
chunks: true,
130-
modules: true,
131-
chunkModules: true,
132-
assets: true,
133-
ids: true,
134-
hash: true,
135-
errors: true,
136-
warnings: true,
137-
});
127+
cached =
128+
compiler.options.name === 'lynx'
129+
? stats.toJson()
130+
: stats.toJson({
131+
all: false,
132+
chunks: true,
133+
modules: true,
134+
chunkModules: true,
135+
assets: true,
136+
ids: true,
137+
hash: true,
138+
errors: true,
139+
warnings: true,
140+
});
138141
return cached;
139142
};
140143
})();

0 commit comments

Comments
 (0)