Pin Pro react-on-rails-rsc peer to an explicit ^19.0.5 range (#3965)#4082
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✅ Files skipped from review due to trivial changes (2)
WalkthroughThe Pro package's optional ChangesPin react-on-rails-rsc peer dependency to ^19.0.5
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related issues
Possibly related PRs
Suggested labels
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is ON. A cloud agent has been kicked off to fix the reported issue.
Reviewed by Cursor Bugbot for commit c70ff97. Configure here.
Greptile SummaryThis PR replaces the wildcard
Confidence Score: 4/5Safe to merge — the actual package.json change is a one-liner with no runtime impact, and both findings are in documentation/changelog text only. The core change is straightforward and validated by the author (lockfile unchanged, zero new peer warnings). Two issues exist in prose: a wrong PR number in the changelog and a misleading docs note that says 19.2.x requires a deliberate bump while ^19.0.5 actually admits it automatically. Neither affects runtime behaviour, but the docs inaccuracy could confuse future maintainers about when the peer range needs updating. The docs note in docs/pro/react-server-components/upgrading-existing-pro-app.md (and its mirror in llms-full-pro.txt) needs a small reword; CHANGELOG.md needs the PR link corrected from pull/3965 to pull/4082. Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A["Consumer installs react-on-rails-pro"] --> B{"react-on-rails-rsc peer declared?"}
B -- "optional peer ^19.0.5" --> C{"Installed version satisfies ^19.0.5?"}
C -- "19.0.5 <= v < 20.0.0 stable" --> D["Peer satisfied"]
C -- "prerelease or < 19.0.5 or >= 20" --> E["Peer not satisfied (optional, no hard error)"]
C -- "not installed" --> F["Optional, silently skipped"]
D --> G["RSC features available"]
E --> H["Consumer must add override or exact pin"]
F --> I["RSC features disabled"]
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
flowchart TD
A["Consumer installs react-on-rails-pro"] --> B{"react-on-rails-rsc peer declared?"}
B -- "optional peer ^19.0.5" --> C{"Installed version satisfies ^19.0.5?"}
C -- "19.0.5 <= v < 20.0.0 stable" --> D["Peer satisfied"]
C -- "prerelease or < 19.0.5 or >= 20" --> E["Peer not satisfied (optional, no hard error)"]
C -- "not installed" --> F["Optional, silently skipped"]
D --> G["RSC features available"]
E --> H["Consumer must add override or exact pin"]
F --> I["RSC features disabled"]
Reviews (1): Last reviewed commit: "Pin Pro react-on-rails-rsc peer to an ex..." | Re-trigger Greptile |
size-limit report 📦
|
Code Review: Pin Pro
|
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@CHANGELOG.md`:
- Line 29: The CHANGELOG entry for the RSC peer wildcard change contains
misleading wording that suggests future 19.x releases require reviewed PRs, when
in fact the caret range `^19.0.5` allows automatic adoption of any 19.x stable
release. Revise the wording to clarify that this change sets a minimum version
floor while still permitting auto-matching of subsequent 19.x releases, and
emphasize that the key benefit is preventing silent auto-adoption of future
major versions (like 20.0.0) without explicit review and approval.
In `@docs/pro/react-server-components/upgrading-existing-pro-app.md`:
- Around line 39-40: The documentation note incorrectly describes the semver
policy of the `^19.0.5` peer range. The current text claims it "tracks the React
19.0.x runtime line" but this is inaccurate since `^19.0.5` actually permits any
19.x release greater than or equal to 19.0.5 (including 19.1.x, 19.2.x, etc.).
Reword the note to accurately reflect that the caret range allows later stable
19.x releases, and ensure it clearly emphasizes that bumping the peer range is a
deliberate, reviewed change made in coordination with generator and React range
updates, not an automatic adoption of future releases.
In `@llms-full-pro.txt`:
- Around line 8115-8116: The wording "It tracks the React 19.0.x runtime line"
in the NOTE section about the `react-on-rails-rsc` peer range is misleading
because the semver specification `^19.0.5` actually permits any 19.x release
(including 19.1.x, 19.2.x, and beyond) up to but not including 20.0.0, not just
versions in the 19.0.x line. Clarify this by replacing the sentence to
explicitly state that the peer range allows later stable 19.x releases while
keeping 19.0.5 as the minimum floor, making it clear that bumping to 19.2.x (or
future 19.x versions) falls within the existing semver constraints rather than
being an expansion of the range itself.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 0c4a0ac2-2825-4bcc-8a7d-e4339deafbad
📒 Files selected for processing (4)
CHANGELOG.mddocs/pro/react-server-components/upgrading-existing-pro-app.mdllms-full-pro.txtpackages/react-on-rails-pro/package.json
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c70ff9783c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Address review-bot wording-accuracy feedback (claude, greptile, coderabbit). The `"*"` -> `^19.0.5` peer change itself is correct and unchanged; only the prose describing it was inaccurate. `^19.0.5` means `>= 19.0.5 < 20.0.0`, which admits ALL of `19.x >= 19.0.5` (including `19.1.x` and `19.2.x`). It does not "track the React 19.0.x runtime line" and does not gate `19.2.x` behind review. - Docs note: reworded to describe the advisory range accurately — floor at `19.0.5` (RSC CSS FOUC fix), ceiling below `20.0.0` (a new react-on-rails-rsc major is a deliberate, reviewed bump), and that within `19.x` the real per-version compatibility gate is the Pro node renderer runtime version check (rscPeerSupport.ts: rsc 19.0.x<->react 19.0.4+, rsc 19.2.x<->react 19.2.7+), not this peer range. - CHANGELOG: same accurate framing; fixed the PR link from /pull/3965 (the issue) to PR 4082 while keeping Fixes Issue 3965. - Regenerated llms-full-pro.txt to mirror the doc change. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replace the Pro npm package's optional react-on-rails-rsc peer wildcard "*" with an explicit "^19.0.5" range. The wildcard auto-adopted any future stable react-on-rails-rsc (including a future 19.2.x line with a different React peer requirement) with no coordinated review, and "*" never matched prereleases anyway. The ^19.0.5 range encodes the RSC CSS FOUC floor (>= 19.0.5), admits the future 19.2.x stable line within major 19, and excludes < 19.0.5 and 20+. peerDependenciesMeta stays optional: true and the devDependencies pin is untouched. Both "*" and "^19.0.5" exclude prereleases by semver, so the in-repo Pro/RSC dummy (which resolves react-on-rails-rsc@19.2.0-rc.1 via a direct dependency + pnpm override) is unaffected: pnpm install produces no new peer warning and pnpm-lock.yaml is unchanged. Document the version coupling in the Pro RSC upgrade guide and add an Unreleased CHANGELOG entry. Regenerate llms-full-pro.txt to mirror the doc change. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Address review-bot wording-accuracy feedback (claude, greptile, coderabbit). The `"*"` -> `^19.0.5` peer change itself is correct and unchanged; only the prose describing it was inaccurate. `^19.0.5` means `>= 19.0.5 < 20.0.0`, which admits ALL of `19.x >= 19.0.5` (including `19.1.x` and `19.2.x`). It does not "track the React 19.0.x runtime line" and does not gate `19.2.x` behind review. - Docs note: reworded to describe the advisory range accurately — floor at `19.0.5` (RSC CSS FOUC fix), ceiling below `20.0.0` (a new react-on-rails-rsc major is a deliberate, reviewed bump), and that within `19.x` the real per-version compatibility gate is the Pro node renderer runtime version check (rscPeerSupport.ts: rsc 19.0.x<->react 19.0.4+, rsc 19.2.x<->react 19.2.7+), not this peer range. - CHANGELOG: same accurate framing; fixed the PR link from /pull/3965 (the issue) to PR 4082 while keeping Fixes Issue 3965. - Regenerated llms-full-pro.txt to mirror the doc change. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
02ea3f9 to
c16a723
Compare
|
Review-thread triage (rebased onto merged #4080/#4078, now head reflects stable
Resolving. |
Code ReviewSummary: Replaces the Pro package's optional Correctness
Documentation (minor observation)The new CHANGELOGEntry is detailed, accurate, and correctly cross-references the issue and related PRs. No concerns on
|
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@docs/pro/react-server-components/upgrading-existing-pro-app.md`:
- Line 38: Remove the empty blockquote marker on line 38 of the
upgrading-existing-pro-app.md file. The line contains only a `>` character with
no content, which violates the markdown no-blanks-blockquote rule. Either delete
this line entirely or if a blank line is needed between blockquote sections,
place it outside the blockquote by removing the `>` marker completely.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: d7dff8ec-6d0e-40e1-8b15-1468715460f6
📒 Files selected for processing (4)
CHANGELOG.mddocs/pro/react-server-components/upgrading-existing-pro-app.mdllms-full-pro.txtpackages/react-on-rails-pro/package.json
✅ Files skipped from review due to trivial changes (1)
- CHANGELOG.md
🚧 Files skipped from review as they are similar to previous changes (2)
- packages/react-on-rails-pro/package.json
- llms-full-pro.txt
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c16a7232cd
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Addresses MD028 (blank line between consecutive blockquotes) and the two-stacked-NOTE readability concern by introducing a plain-text bridge that distinguishes the app-level exact pin from the Pro package's optional peer advisory. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Review-thread triage (head
|
Code ReviewOverview: Replaces What's good
Minor concerns1. Cognitive tension with the adjacent NOTE in the docs The existing note just above the new addition reads:
The very next block (added here) says the peer range 2. The diff is byte-identical to the doc change, which is correct. Worth confirming this file is always regenerated from the docs source (not hand-edited), so no drift can happen silently. 3. No test or runtime change required Confirmed — the peer range is advisory metadata only. VerdictApprove. The change is correct, well-reasoned, and the documentation separating "app pin" from "Pro peer range" is a genuine improvement. The doc clarity note above is optional — worth considering in a follow-up pass, but not a blocker. |
| > [!NOTE] | ||
| > The generator pins `react-on-rails-rsc` to exactly `19.0.5` (no `^` or `~`). Because the RSC bundler APIs are version-coupled, record `react-on-rails-rsc` as exactly `19.0.5` in `package.json` rather than the default caret range so a later `19.1.x`/`19.2.x` is not picked up; `react` and `react-dom` stay on `~19.0.4`. This is separate from the Pro package peer metadata tracked in [issue #3609](https://github.com/shakacode/react_on_rails/issues/3609): metadata can allow RSC packages broadly enough for `npm ls`, while the generator still installs the tested exact RSC package pin. | ||
|
|
||
| That exact pin is what goes in your app's `package.json`. Separately, the Pro package itself declares an optional peer range, which is broader on purpose: |
There was a problem hiding this comment.
The two back-to-back NOTE callouts are technically correct but create a mild contradiction for anyone reading top-to-bottom: the previous NOTE says the generator deliberately avoids React 19.1/19.2, then this one says the peer range "admits" them. A short bridging sentence would close the gap, e.g.:
The advisory peer range is intentionally wider than the generator pin: the generator controls what goes into a new app, while the peer metadata simply tells
npm ls/pnpmwhat is structurally compatible. The real per-version gate isrscPeerSupport.ts, not this range.
Optional, not a blocker.

Why
packages/react-on-rails-pro/package.jsondeclared the optional peer"react-on-rails-rsc": "*". The wildcard accepts any version — including pre-19.0.5builds that lack the RSC CSS FOUC fix, and a future major (20.x) — and, because semver*never matches prereleases, RC rollouts already require explicit overrides. So*provided no convenience while admitting known-bad floors.This replaces
"*"with an explicit^19.0.5(=>=19.0.5 <20.0.0):19.0.5— the RSC CSS FOUC fix requirement (the stable pin landed in RSC FOUC: ship stable react-on-rails-rsc@19.0.5 and pin v17 to it (native-only) #3634), so pre-FOUC builds are excluded.<20.0.0— a newreact-on-rails-rscmajor is a deliberate, reviewed bump rather than silently accepted.19.xline (19.0.x,19.2.x, …), the actual per-version compatibility gate is the Pro node-renderer runtime version check (rscPeerSupport.ts, which tiers rsc19.0.x↔react19.0.4+and rsc19.2.x↔react19.2.7+), not this advisory optional peer range.^19.0.5intentionally admits the supported19.2.xline so the React 19.2 path isn't blocked by a peer warning.No regression to the React 19.2 soak
The in-repo Pro/RSC dummy resolves
react-on-rails-rsc@19.2.0-rc.1(a prerelease) via a direct dependency + pnpm override. Both"*"and^19.0.5exclude prereleases by semver, so resolution is unchanged:pnpm installproduces zeroreact-on-rails-rscpeer warnings before and after, andpnpm-lock.yamlis byte-identical (md5 unchanged).Changes
packages/react-on-rails-pro/package.json: peerreact-on-rails-rsc"*"→"^19.0.5"(staysoptional; devDependency untouched).docs/pro/react-server-components/upgrading-existing-pro-app.md: note documenting the floor/ceiling meaning and that the runtime version check is the real per-version gate.llms-full-pro.txtregenerated to match.CHANGELOG.md:[Unreleased]entry.Validation (local, all green)
pnpm run type-check,pnpm run lint,prettier --check,script/check-docs-sidebar: clean."*"baseline.Notes
19.0.5pin). Will be rebased onto merged RSC FOUC: ship stable react-on-rails-rsc@19.0.5 and pin v17 to it (native-only) #3634 (which flips the install docs from19.0.5-rc.7to stable19.0.5, so the doc install version matches this^19.0.5floor).Fixes #3965
Note
Low Risk
Metadata and documentation only; optional peer range is advisory and does not change runtime RSC rendering logic.
Overview
Replaces the Pro package’s optional
react-on-rails-rscpeer dependency from"*"with^19.0.5(>= 19.0.5 < 20.0.0), so npm/pnpm installs are advised against pre-FOUC19.xbuilds and against an unreviewed20.xmajor while still allowing supported19.1+/19.2.xwithin the line.RSC upgrade docs (and regenerated
llms-full-pro.txt) now separate the generator’s exact19.0.5app pin from this broader Pro peer range, and note thatrscPeerSupport.tsruntime checks remain the real per-version gate.CHANGELOG.mdrecords the change under[Unreleased].Reviewed by Cursor Bugbot for commit 09a5c25. Bugbot is set up for automated code reviews on this repo. Configure here.
Summary by CodeRabbit
Changed
"*"to^19.0.5(advisory>= 19.0.5 < 20.0.0).Documentation
19.0.5minimum, the ceiling before20.0.0, and that actual per-Version compatibility is verified through runtime checks rather than the peer range alone.