Skip to content

Commit c4f06ae

Browse files
chore: note the webpack peer bump for the next major in the fallback TODOs
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01UjuMAuk9o6UazjHzcAQCTA
1 parent 0c8717e commit c4f06ae

2 files changed

Lines changed: 7 additions & 4 deletions

File tree

‎lib/Server.js‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4097,8 +4097,9 @@ class Server {
40974097
// `MultiHook` firing once per child, so `onShutdown` is guarded. Tapping it
40984098
// with `tapPromise` also lets `compiler.close()` await the server actually
40994099
// stopping, so the port is released before the next start.
4100-
// TODO remove this fallback in the next major, once the minimum supported
4101-
// webpack (5.110.0) has `MultiCompiler.hooks.shutdown`, and tap
4100+
// TODO in the next major, bump the webpack peer dependency to `^5.112.0`
4101+
// (`MultiCompiler.hooks.shutdown` since 5.110.0, top-level `plugins` of a
4102+
// multi-configuration since 5.112.0), remove this fallback and tap
41024103
// `compiler.hooks.shutdown` alone.
41034104
const shutdownCompilers = /** @type {Compiler} */ (compiler).hooks.shutdown
41044105
? [compiler]

‎test/e2e/api-plugin.test.js‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ const __dirname = path.dirname(fileURLToPath(import.meta.url));
2121
const port = portsMap["api-plugin"];
2222
const [portA, portB] = portsMap["api-plugin-multi"];
2323

24-
// TODO remove this check in the next major, once the minimum supported webpack
25-
// applies the top-level `plugins` of a multi-configuration to the MultiCompiler.
24+
// TODO in the next major, once the webpack peer dependency is `^5.112.0`, remove
25+
// this check: the top-level `plugins` of a multi-configuration always apply.
2626
const supportsMultiCompilerPlugins =
2727
new webpack.MultiCompiler([], { plugins: [] }).options.plugins !== undefined;
2828

@@ -701,6 +701,8 @@ describe("API (plugin)", () => {
701701
},
702702
);
703703

704+
// TODO remove in the next major, together with the fallback it covers in
705+
// `Server#apply()`, once the webpack peer dependency is `^5.112.0`.
704706
it("should stop the server once on webpack without `MultiCompiler.hooks.shutdown`", async () => {
705707
const compiler = webpack(multiCompilerConfig);
706708
// A webpack older than 5.110.0: the same compiler, minus the hook.

0 commit comments

Comments
 (0)