Skip to content

Commit 111e644

Browse files
justin808claude
andcommitted
Pin react-on-rails-rsc to stable 19.0.5 (#3634)
Stable react-on-rails-rsc@19.0.5 is now published on npm latest, so flip every default/published pin from the 19.0.5-rc.7 prerelease to the stable 19.0.5 release. This is the v17 final pin. - Generator default RSC_PACKAGE_VERSION_PIN -> "19.0.5"; reword the pin comment to stable framing and drop the resolved TODO(#3642). - Update js_dependency_manager_spec assertions and warning-text/literal expectations from 19.0.5-rc.7 to 19.0.5 (the unrelated 19.1.0-rc.1 stub_const is left as-is). - Root package.json devDependency and pnpm-overrides comment, plus the Pro package devDependency, now pin 19.0.5. - Regenerate pnpm-lock.yaml: the react-on-rails-rsc 19.0.5-rc.7 entries become 19.0.5; the intentional 19.2.0-rc.1 soak entries are untouched. - Reword the Pro RSC install docs (rspack-compatibility, create-without-ssr, upgrading-existing-pro-app) to state stable 19.0.5 is the pin. - Regenerate llms-full-pro.txt to mirror the Pro doc edits. - Add a [Unreleased] CHANGELOG entry; note the native RSC CSS FOUC fix requires react-on-rails-rsc >= 19.0.5. Intentionally left untouched: the React 19.2 soak pins (react_on_rails_pro_dummy override + Pro dummy package, 19.2.0-rc.1 / react 19.2.7), the Pro package peerDependencies "*", and the node-renderer RSC peer-support files. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent d5aa5c7 commit 111e644

10 files changed

Lines changed: 58 additions & 55 deletions

File tree

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@ After a release, run `/update-changelog` in Claude Code to analyze commits, writ
2828

2929
- **Owner Stacks in development error reports**: When a React component throws during rendering, React on Rails now enriches its development error reporting with React 19.1+'s dev-only [`captureOwnerStack`](https://react.dev/reference/react/captureOwnerStack) output — the chain of components that rendered the failing one (e.g. `at Avatar` / `at PostCard` / `at PostList`). On the **server-side rendering** path, the owner stack is captured synchronously inside the Pro streaming `onError` callback and appended to the error's stack, so it flows through to the Rails-side `ReactOnRails::PrerenderError` / `SmartError` (`:server_rendering_error`) output and the streamed shell-error HTML. On the **client**, recoverable hydration mismatches (`onRecoverableError`) automatically gain an owner-stack line in the branded development log, and apps that register their own `onCaughtError`/`onUncaughtError` handler get an additive `[ReactOnRails] Render error ... Owner stack:` line for client render errors. To avoid displacing React's own built-in development diagnostics (component stacks, error-boundary hints), React on Rails does not auto-attach caught/uncaught handlers solely to log owner stacks. Owner-stack capture requires React >= 19.1 running its development build, so it is a strict no-op on older React and in all production builds (no capture, no `captureOwnerStack` call), asserted by tests. The ExecJS rendering path is out of scope (capture must happen JS-side, synchronously, inside React's error callback). Closes [Issue 3887](https://github.com/shakacode/react_on_rails/issues/3887). [PR 4089](https://github.com/shakacode/react_on_rails/pull/4089) by [justin808](https://github.com/justin808).
3030

31+
#### Changed
32+
33+
- **[Pro]** **Pinned `react-on-rails-rsc` to the stable `19.0.5` release**: The generator default, the root and Pro package manifests, the lockfile, and the Pro RSC install docs now pin the stable `react-on-rails-rsc@19.0.5` (previously the `19.0.5-rc.7` prerelease). The native RSC CSS FOUC fix requires `react-on-rails-rsc >= 19.0.5`. Closes [Issue 3634](https://github.com/shakacode/react_on_rails/issues/3634). [PR 4080](https://github.com/shakacode/react_on_rails/pull/4080) by [justin808](https://github.com/justin808).
34+
3135
### [17.0.0.rc.5] - 2026-06-16
3236

3337
#### Fixed

docs/pro/react-server-components/create-without-ssr.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,19 +23,19 @@ yarn add --exact react-on-rails-pro@VERSION
2323
bundle add react_on_rails_pro --version="= VERSION"
2424
```
2525

26-
Also, install React 19.0.x, React DOM 19.0.x, and the exact `react-on-rails-rsc` release candidate currently used by the generator:
26+
Also, install React 19.0.x, React DOM 19.0.x, and the exact `react-on-rails-rsc` release currently used by the generator:
2727

2828
```bash
29-
yarn add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5-rc.7
30-
# npm install react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5-rc.7
31-
# pnpm add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5-rc.7
32-
# bun add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5-rc.7
29+
yarn add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5
30+
# npm install react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5
31+
# pnpm add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5
32+
# bun add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5
3333
```
3434

3535
> [!NOTE]
3636
> React on Rails Pro RSC currently supports React 19.0.x with patch >= 19.0.4. Do not upgrade generated RSC apps to React 19.1 or 19.2 just because those versions are newer on npm; the RSC bundler APIs used internally can change between React minor versions. See the [React documentation on Server Components](https://react.dev/reference/rsc/server-components#how-do-i-build-support-for-server-components) for details.
3737
>
38-
> The example above pins `react-on-rails-rsc@19.0.5-rc.7`, a release candidate. Keep that exact pin until a stable `react-on-rails-rsc@19.0.5` release is published and the generator/package metadata policy is reviewed together.
38+
> The example above pins the stable `react-on-rails-rsc@19.0.5` release exactly, matching the generator default.
3939
4040
2. Enable support for Server Components in React on Rails Pro configuration:
4141

docs/pro/react-server-components/rspack-compatibility.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ The generator supports Rspack — when `assets_bundler: rspack` is detected in `
1212
The RSC implementation depends on the `react-on-rails-rsc` npm package, which provides bundler-specific manifest plugins plus a shared loader:
1313

1414
- **WebpackPlugin** (`react-on-rails-rsc/WebpackPlugin`) — generates client/server component manifest files under webpack.
15-
- **RspackPlugin** (`react-on-rails-rsc/RspackPlugin`) — the rspack-native equivalent (`RSCRspackPlugin`). It emits the **same manifest JSON schema** using only standard rspack public APIs, so the RSC runtime resolves client references identically. Exported by the exact `react-on-rails-rsc@19.0.5-rc.7` pin (switch to 19.0.5 stable once published).
15+
- **RspackPlugin** (`react-on-rails-rsc/RspackPlugin`) — the rspack-native equivalent (`RSCRspackPlugin`). It emits the **same manifest JSON schema** using only standard rspack public APIs, so the RSC runtime resolves client references identically. Exported by the stable `react-on-rails-rsc@19.0.5` pin.
1616
- **WebpackLoader** (`react-on-rails-rsc/WebpackLoader`) — transforms `'use client'` files into client reference proxies in the RSC bundle. Works under both webpack and rspack.
1717

1818
## React and Package Version Policy
@@ -24,8 +24,8 @@ integration can change between React minor releases, so the generator range shou
2424
advance only after the Webpack and Rspack paths are verified against the new React
2525
minor.
2626

27-
The generator separately pins `react-on-rails-rsc@19.0.5-rc.7` exactly until a
28-
stable `react-on-rails-rsc@19.0.5` is published. That package pin is separate from
27+
The generator separately pins the stable `react-on-rails-rsc@19.0.5` release
28+
exactly. That package pin is separate from
2929
the Pro package peer metadata tracked in [issue #3609](https://github.com/shakacode/react_on_rails/issues/3609):
3030
metadata can allow prerelease RSC packages broadly enough for `npm ls`, while the
3131
generator still installs the tested React range and exact RSC package pin.

docs/pro/react-server-components/upgrading-existing-pro-app.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,17 @@ Before running the generator, verify your environment:
1515
| React on Rails Pro npm | `npm ls react-on-rails-pro` / `yarn why react-on-rails-pro` / `pnpm list react-on-rails-pro` / `bun pm why react-on-rails-pro` | Matches gem version |
1616
| React version | `npm ls react` / `yarn why react` / `pnpm list react` / `bun pm why react` | 19.0.x with patch >= 19.0.4 (see [v16.2.0 release notes](../../oss/upgrading/release-notes/16.2.0.md) for security context) |
1717
| React DOM version | `npm ls react-dom` / `yarn why react-dom` / `pnpm list react-dom` / `bun pm why react-dom` | Must match `react` version |
18-
| `react-on-rails-rsc` | `npm ls react-on-rails-rsc` / `yarn why react-on-rails-rsc` / `pnpm list react-on-rails-rsc` / `bun pm why react-on-rails-rsc` | Exact `19.0.5-rc.7` pin until stable `19.0.5` ships |
18+
| `react-on-rails-rsc` | `npm ls react-on-rails-rsc` / `yarn why react-on-rails-rsc` / `pnpm list react-on-rails-rsc` / `bun pm why react-on-rails-rsc` | Exact stable `19.0.5` pin |
1919
| Node.js | `node --version` | 18+ |
2020
| Pro initializer exists | `ls config/initializers/react_on_rails_pro.rb` | File exists |
2121
| Node renderer configured | Check `react_on_rails_pro.rb` for `server_renderer = "NodeRenderer"` | NodeRenderer enabled |
2222

2323
If React is outside the supported 19.0.x range or below 19.0.4, upgrade it first:
2424

2525
```bash
26-
pnpm add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5-rc.7
27-
# or: yarn add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5-rc.7
28-
# or: npm install react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5-rc.7
26+
pnpm add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5
27+
# or: yarn add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5
28+
# or: npm install react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5
2929
```
3030

3131
> **React 19.0.x with patch >= 19.0.4** is recommended. Earlier 19.0.x versions (19.0.0--19.0.3) have known security vulnerabilities — see the [v16.2.0 release notes](../../oss/upgrading/release-notes/16.2.0.md) for details.
@@ -34,7 +34,7 @@ pnpm add react@~19.0.4 react-dom@~19.0.4 react-on-rails-rsc@19.0.5-rc.7
3434
> The RSC generator intentionally stays on React 19.0.x and does not widen generated apps to React 19.1 or 19.2 yet. React's RSC runtime and bundler APIs can change between minor releases, so advance the React range only when the generator, docs, and package metadata policy are reviewed together.
3535
3636
> [!NOTE]
37-
> `react-on-rails-rsc@19.0.5-rc.7` is an exact release-candidate pin. Keep that exact pin until a stable `react-on-rails-rsc@19.0.5` release is available. 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 prerelease RSC packages broadly enough for `npm ls`, while the generator still installs the tested exact RSC package pin.
37+
> `react-on-rails-rsc@19.0.5` is the exact stable pin used by the generator. 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.
3838
3939
## Pre-Migration: Audit Components for Client API Usage
4040

@@ -263,8 +263,8 @@ Then run `bundle install` before retrying the generator.
263263

264264
If the RSC bundle build fails but server and client builds succeed, the issue is likely in `rscWebpackConfig.js`. Common causes:
265265

266-
- **Missing `react-on-rails-rsc` package**: Run `pnpm add react-on-rails-rsc@19.0.5-rc.7`
267-
- **React or `react-on-rails-rsc` version mismatch**: RSC currently requires React 19.0.x with patch >= 19.0.4 and the exact `react-on-rails-rsc@19.0.5-rc.7` pin. Check with `pnpm list react react-dom react-on-rails-rsc`
266+
- **Missing `react-on-rails-rsc` package**: Run `pnpm add react-on-rails-rsc@19.0.5`
267+
- **React or `react-on-rails-rsc` version mismatch**: RSC currently requires React 19.0.x with patch >= 19.0.4 and the exact `react-on-rails-rsc@19.0.5` pin. Check with `pnpm list react react-dom react-on-rails-rsc`
268268
- **Custom webpack config incompatibility**: If your `serverWebpackConfig.js` was heavily customized, the generator's transforms may not apply cleanly. See [Preparing Your App: Step 4](../../oss/migrating/rsc-preparing-app.md#step-4-set-up-the-rsc-webpack-bundle) for the underlying intent of each webpack change
269269

270270
### Manifest Files Not Generated

0 commit comments

Comments
 (0)