Skip to content

build(ui): Enable react compiler annotation, rspack 2.1#118033

Draft
scttcper wants to merge 1 commit into
masterfrom
scttcper/rspack-react-compiler
Draft

build(ui): Enable react compiler annotation, rspack 2.1#118033
scttcper wants to merge 1 commit into
masterfrom
scttcper/rspack-react-compiler

Conversation

@scttcper

Copy link
Copy Markdown
Member

i tried reactCompiler: true and it panics in rust. but this option works https://react.dev/reference/react-compiler/configuration#compilation-control this requires components opt in via 'use memo';

@scttcper scttcper requested a review from a team as a code owner June 18, 2026 16:44
@scttcper scttcper marked this pull request as draft June 18, 2026 16:44
@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Jun 18, 2026
@scttcper scttcper changed the title feat(ui): Enable react compiler annotation feat(ui): Enable react compiler annotation, rspack 2.1 Jun 18, 2026
@scttcper scttcper changed the title feat(ui): Enable react compiler annotation, rspack 2.1 build(ui): Enable react compiler annotation, rspack 2.1 Jun 18, 2026
Comment thread pnpm-lock.yaml
Comment on lines 2995 to +2997
peerDependencies:
'@module-federation/runtime-tools': ^0.24.1 || ^2.0.0
'@swc/helpers': '>=0.5.1'
'@swc/helpers': ^0.5.23

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Bug: The lockfile resolves @swc/helpers to 0.5.15, which does not satisfy the ^0.5.23 peer dependency from the newly updated @rspack/core@2.1.0-beta.0, risking runtime errors.
Severity: MEDIUM

Suggested Fix

Ensure the version of @swc/helpers in the lockfile is upgraded to at least 0.5.23 to satisfy the peer dependency requirement of @rspack/core@2.1.0-beta.0. This can be done by running pnpm install or manually updating the lockfile to resolve the correct version.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent. Verify if this is a real issue. If it is, propose a fix; if not, explain why it's
not valid.

Location: pnpm-lock.yaml#L2995-L2997

Potential issue: The update to `@rspack/core@2.1.0-beta.0` introduces a peer dependency
requirement for `@swc/helpers` of version `^0.5.23`. However, the `pnpm-lock.yaml` file
resolves `@swc/helpers` to version `0.5.15`, which violates this semantic versioning
constraint. This mismatch, especially when using a beta version of `rspack`, could lead
to runtime failures because `rspack` may rely on helpers or changes that were introduced
in the newer versions of `@swc/helpers`. While the peer dependency is marked as
optional, the explicit version requirement suggests it's necessary for certain
functionalities to work correctly.

Also affects:

  • package.json:101~108

Did we get this right? 👍 / 👎 to inform future reviews.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

swc only used w/ jest, its fine but can fix as it gets closer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant