feat: annotate schema options with added keywords - #21473
#21473feat: annotate schema options with added keywords#21473bjohansebas merged 5 commits intowebpack:mainwebpack/webpack:mainfrom bjohansebas:feat/schema-since-default-annotationsbjohansebas/webpack:feat/schema-since-default-annotationsCopy head branch name to clipboard
Conversation
🦋 Changeset detectedLatest commit: 9018e85 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
59e6563 to
27fa1ab
Compare
Merging this PR will regress 1 benchmark
|
| Mode | Benchmark | BASE |
HEAD |
Efficiency | |
|---|---|---|---|---|---|
| ❌ | Memory | benchmark "many-modules-esm", scenario '{"name":"mode-production","mode":"production"}' |
7.5 MB | 9.9 MB | -24.25% |
| ⚡ | Memory | benchmark "devtool-eval", scenario '{"name":"mode-development-rebuild","mode":"development","watch":true}' |
3.1 MB | 1.3 MB | ×2.4 |
Tip
Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.
Comparing bjohansebas:feat/schema-since-default-annotations (9018e85) with main (ec39088)
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #21473 +/- ##
==========================================
+ Coverage 93.78% 93.80% +0.01%
==========================================
Files 620 620
Lines 73330 73324 -6
Branches 21203 21203
==========================================
+ Hits 68771 68779 +8
+ Misses 4559 4545 -14
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
4b49a3a to
8db43f6
Compare
7c619f4 to
e48b158
Compare
e48b158 to
9018e85
Compare
|
This PR is packaged and the instant preview is available (774e7e4). Install it locally:
npm i -D webpack@https://pkg.pr.new/webpack@774e7e4
yarn add -D webpack@https://pkg.pr.new/webpack@774e7e4
pnpm add -D webpack@https://pkg.pr.new/webpack@774e7e4 |
Summary
What kind of change does this PR introduce?
Did you add tests for your changes?
Does this PR introduce a breaking change?
If relevant, what needs to be documented once your changes are merged or what have you already documented?
Use of AI
Note
Low Risk
Documentation and generated types only; no runtime behavior or config validation changes beyond stripping doc-only schema keywords.
Overview
Adds version metadata to webpack’s public TypeScript surface so IDEs and docs can show when options and hooks were introduced.
Schema entries gain an
"added": "<version>"keyword (and existingexperimentalis documented in AGENTS.md); tooling v1.27.0 turns those into@since(and@experimental) on generatedWebpackOptionsdeclarations. Many newer options (resource hints, HTML output, CSS parsers, etc.) are tagged 5.109.0 where appropriate;experiments.*now carry@sincefor their original release versions.Plugin hooks are refactored to
createCompilationHooks()factories with inline@sinceon each hook (e.g. HtmlModulesPlugin, JavascriptModulesPlugin, NormalModule, Compiler, Compilation), andgetCompilationHooksreturn types are inlined intypes.d.tsso hook versions appear on the public API.Reviewed by Cursor Bugbot for commit 9018e85. Bugbot is set up for automated code reviews on this repo. Configure here.