Repository navigation
Conversation
|
This was referenced Sep 26, 2026
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Correct the
experiments.optimization.targetdocumentation to match the current Webpack and Rspack plugin behavior:ENV_TARGETis not inferred from the bundler'stargetoption.target: 'web'explicitly for browser builds so Node.js-specific loader code can be removed at compile time.target: 'node'explicitly for Node.js builds, including SSR scenarios.Search findings:
ENV_TARGETas a compile-time value supplied by the build configuration and preserves a runtime fallback when it is absent.be54b58removed inference from both plugins and explicitly documented thatENV_TARGETis only set manually.ENV_TARGETtree-shaking path and added emitted-output coverage; the existing fixture still asserts thatENV_TARGETis absent unless configured.Because the core plugin behavior and tests intentionally reject inference, this is a documentation-only correction; no code or changeset is included.
Validation:
git diff --checkpassed. The targeted Prettier check was attempted but could not run because this container has Node.js 20.19.2 while the repository's pnpm requires Node.js 22.13+ (the repository CI uses Node.js 24).Related Issue
Historical context: #4452 (closed). This PR documents the behavior implemented by its follow-up work and does not alter that fix.
Types of changes
Checklist