Skip to content

feat(turbopack): support merged PostCSS configs - #186

Merged
fireairforce merged 1 commit into
utoofrom
zoomdong/postcss-config-merged
Aug 24, 2026
Merged

fireairforce merged 1 commit into
utoofrom
zoomdong/postcss-config-merged

Conversation

@fireairforce

@fireairforce fireairforce commented Aug 24, 2026 •

Copy link
Copy Markdown
Member

Summary

  • discover a PostCSS config file even when inline config content is supplied
  • append inline plugins after file plugins in a single PostCSS pass
  • keep the existing runtime postcss.ts implementation unchanged
  • preserve config-file invalidation and the existing file-only/inline-only paths

Motivation

Utoopack integrations need to inject framework PostCSS plugins without suppressing a user-owned postcss.config.* file. Previously inline config short-circuited config discovery, so the two sources were mutually exclusive.

Implementation

The change is isolated to Rust. File-only and inline-only configurations continue through the original executor path. When both sources exist, Rust creates a lightweight virtual config module that resolves the two configs sequentially and concatenates their plugin declarations, then passes that single config to the unchanged runtime executor.

Downstream

Verification

  • cargo fmt --all and git diff --check
  • cargo check -p turbopack-node -p turbopack --lib
  • cargo clippy -p turbopack-node -p turbopack --lib -- -D warnings
  • downstream Utoopack snapshots cover file-only, inline-only, and merged configurations

@fireairforce
fireairforce force-pushed the zoomdong/postcss-config-merged branch from 9c9823c to 4b00998 Compare August 24, 2026 07:51
@fireairforce
fireairforce marked this pull request as ready for review August 24, 2026 07:53
@fireairforce
fireairforce merged commit 4e779b4 into utoo Aug 24, 2026
15 of 29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant