Merged
Conversation
✅ Deploy Preview for tsdown-main ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
tsdown
create-tsdown
@tsdown/css
@tsdown/exe
tsdown-migrate
commit: |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes CSS @import resolution for LightningCSS when importing styles from packages under node_modules (e.g. @import "pkg/path.css"), addressing issue #794.
Changes:
- Add module resolution via
oxc-resolverfor LightningCSS bundling, enablingnode_modulesimport resolution. - Extend CSS tests and snapshots to cover
@importfrom a mock package innode_modulesfor both PostCSS and LightningCSS transformers. - Add
oxc-resolverto the workspace catalog and@tsdown/csspackage dependencies.
Reviewed changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| tests/css.test.ts | Expands @import test coverage to include node_modules-style imports and updates expectations. |
| tests/snapshots/css/postcss-with-import.snap.md | Updates snapshot output to include inlined .lib rules from the imported package CSS. |
| tests/snapshots/css/lightningcss-transformer-with-import.snap.md | Updates snapshot output to include inlined .lib rules for LightningCSS bundling. |
| pnpm-workspace.yaml | Adds oxc-resolver to the pnpm catalog for consistent dependency management. |
| pnpm-lock.yaml | Locks oxc-resolver (and its platform bindings) and updates dependency graph accordingly. |
| packages/css/src/lightningcss.ts | Implements oxc-resolver-based resolution inside LightningCSS bundling to support node_modules CSS imports. |
| packages/css/package.json | Declares oxc-resolver as a dependency of @tsdown/css. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
18889d4 to
03d1c61
Compare
Collaborator
Author
|
@sxzz I've resolved the merge conflict. |
sxzz
approved these changes
Mar 5, 2026
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
Closes #794
Linked Issues
Additional context