Skip to content

Conversation

@tclxshunquan-wang
Copy link
Contributor

@tclxshunquan-wang tclxshunquan-wang commented Jun 27, 2025

update swc versions
swc = { version = "=28.0.0" }
swc_config = { version = "3.1.1" }
swc_config = { version = "3.1.1" }
swc_core = { version = "=29.1.4", default-features = false, features = ["parallel_rayon"] }
swc_atoms = { version = "6.0.0" }
swc_ecma_transforms_react = { version = "20.0.0" }
swc_ecma_transforms_testing = { version = "21.0.0" }
testing = { version = "14.0.0" }

Summary by CodeRabbit

  • Chores
    • Updated multiple SWC-related dependencies to newer versions for improved compatibility and maintenance.
    • Upgraded @rspack/cli and @rspack/core to version 1.4.0 in example projects.
    • Documented the SWC dependency update in the changelog.

@coderabbitai
Copy link

coderabbitai bot commented Jun 27, 2025

Walkthrough

This update increases the versions of several dependencies across the project. The SWC-related crates in Rust's Cargo.toml are upgraded, as well as the @rspack/cli and @rspack/core packages in two example JavaScript projects. Additionally, the @swc/core package version is bumped in the inspector plugin’s package.json, and a new changeset documents the SWC dependency bump for the @hyperse/inspector-swc-plugin package. No code or API changes are introduced.

Changes

File(s) Change Summary
.changeset/full-doodles-hammer.md Added a changeset documenting a patch update for SWC dependency bump.
Cargo.toml Updated versions for multiple swc-related Rust crate dependencies.
examples/example-nextjs/package.json,
examples/example-rspack/package.json
Bumped @rspack/cli and @rspack/core from 1.3.13 to 1.4.0 in devDependencies.
crates/inspector-swc-plugin/package.json Updated @swc/core devDependency from 1.11.29 to 1.12.1.

Poem

Up the versions, hop they go,
SWC and Rspack in a row.
No code to tweak, just numbers rise,
Dependencies fresh as springtime skies.
A bunny’s cheer for updates neat—
All the packages skip to a new beat!
🐇✨


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a1347b4 and e2813e1.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (1)
  • crates/inspector-swc-plugin/package.json (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • crates/inspector-swc-plugin/package.json
⏰ Context from checks skipped due to timeout of 90000ms (5)
  • GitHub Check: deploy (20.x)
  • GitHub Check: test (18.x)
  • GitHub Check: test (18.x)
  • GitHub Check: test (18.x)
  • GitHub Check: test (18.x)

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (3)
examples/example-rspack/package.json (1)

42-43: Prefer sem-ver range (^1.4.0) over a hard-pinned patch version.

Locking to "1.4.0" means every micro-fix will require another PR. Unless deterministic builds are required for this example project, switching to "^1.4.0" (or "~1.4.0") reduces maintenance friction while still staying on the same major.

examples/example-nextjs/package.json (1)

46-47: Use a version range to avoid constant bumps.

Same consideration as for the Rspack example: "^1.4.0" keeps you on the latest patch within 1.x without manual intervention.

Cargo.toml (1)

25-29: Pinned with =: consider relax to patch-compatible lock.

Using = freezes even patch updates, which include bug & CVE fixes. Switching to ~28.0.0 (or caret) maintains reproducibility at the minor level but allows safe patch upgrades.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d9df24e and a1347b4.

⛔ Files ignored due to path filters (2)
  • Cargo.lock is excluded by !**/*.lock
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (4)
  • .changeset/full-doodles-hammer.md (1 hunks)
  • Cargo.toml (2 hunks)
  • examples/example-nextjs/package.json (1 hunks)
  • examples/example-rspack/package.json (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
  • GitHub Check: deploy (20.x)
  • GitHub Check: test (18.x)
  • GitHub Check: test (18.x)
🔇 Additional comments (6)
examples/example-rspack/package.json (1)

42-44: Double-check cross-package compatibility.

@rspack/plugin-react-refresh remains at 1.4.3 while @rspack/{cli,core} are now 1.4.0. The plugin occasionally tracks core internals; please run the demo locally to ensure there are no runtime warnings.

examples/example-nextjs/package.json (1)

46-48: Validate that Turbopack still resolves @rspack/* 1.4.0 correctly.

Because Next 15’s Turbopack loader caches rspack binaries aggressively, clear the .next cache or reinstall node_modules before publishing to ensure the new versions are actually picked up.

Cargo.toml (3)

27-29: 👍 Removal of the duplicate swc_config entry.

The workspace now contains a single authoritative declaration, eliminating the cargo warning about duplicate deps.


41-44: Confirm feature flags match your build targets.

swc_core is pulled with default-features = false and only parallel_rayon. Ensure any transforms relying on, e.g., concurrent or plugin features are explicitly turned on elsewhere, otherwise runtime panics may occur at plugin load time.


24-30: ```shell
#!/bin/bash

Search Cargo.lock for swc_common entries to detect multiple versions

if [ -f Cargo.lock ]; then
rg 'name = "swc_common"' -A2 Cargo.lock
else
echo "Cargo.lock not found"
fi


</details>
<details>
<summary>.changeset/full-doodles-hammer.md (1)</summary>

`1-5`: **Changeset looks good.**

Accurately documents the SWC bump for `@hyperse/inspector-swc-plugin`. No further action required.

</details>

</blockquote></details>

</details>

<!-- This is an auto-generated comment by CodeRabbit for review status -->

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.

2 participants