fix: enhance plugin to support alias resolution for css module plugin#7130
Open
ClarkXia wants to merge 6 commits intorelease/nextfrom
Open
fix: enhance plugin to support alias resolution for css module plugin#7130ClarkXia wants to merge 6 commits intorelease/nextfrom
ClarkXia wants to merge 6 commits intorelease/nextfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This pull request enhances the CSS Modules plugin to support path alias resolution, allowing CSS module imports to work correctly with custom path aliases defined in the project configuration. The changes ensure that when CSS modules are imported using aliases, they are properly resolved to their actual file paths during the build process.
Key changes:
- Added alias configuration parameter to CSS Modules plugin across multiple build services
- Integrated alias resolution logic into the CSS module path resolution process
- Exported the AliasWithEmpty type for reuse in the CSS modules plugin
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/ice/src/service/serverCompiler.ts | Passes alias configuration to cssModulesPlugin |
| packages/ice/src/service/preBundleDeps.ts | Adds alias parameter to cssModulesPlugin call |
| packages/ice/src/service/analyze.ts | Exports AliasWithEmpty type for use in other modules |
| packages/ice/src/service/ServerRunner.ts | Includes alias configuration in cssModulesPlugin setup |
| packages/ice/src/esbuild/cssModules.ts | Implements alias resolution logic in the CSS modules plugin |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Collaborator
Author
DONE |
XGHeaven
approved these changes
Sep 10, 2025
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.
This pull request updates the CSS Modules plugin integration across the build pipeline to support path alias resolution, improving how CSS module imports are handled in projects with custom path aliases. The main changes involve passing alias configuration to the CSS Modules plugin and updating its internal logic to resolve paths using these aliases.