Repository navigation
v17.3.0.rc.0
Pre-releaseSecurity
-
[Pro] The RSC generator pins
react-on-rails-rsc19.3.2, which requires the patched Flight runtime:
Publishedreact-on-rails-rsc19.3.1 depends onreact-server-dom-webpack~19.3.0, so an existing app could
upgrade and still resolve Flight 19.3.0, which React's 2026-10-14 advisories (critical RCE
GHSA-xqc2-xf4c-x3h3 and DoS
GHSA-h3gv-c5rc-p453) affect.
react-on-rails-rsc19.3.2 depends on
~19.3.1and peers on React^19.3.1. New RSC apps now install it, and Doctor and the Node renderer's startup
check now require React 19.3.x at 19.3.1 or later withreact-on-rails-rsc19.3.x at 19.3.2 or later. Apps on
react-on-rails-rsc19.3.1 keep working with React 19.3.0, and Doctor still warns about a vulnerable lockfile.
Action required for upgraders: upgradereact-on-rails-rscto 19.3.2 together withreactandreact-dom
19.3.1, remove or update any override or resolution that pinsreact-server-dom-webpackbelow 19.3.1, and confirm
the refreshed lockfile resolves only patchedreact-server-dom-webpackcopies.
#5339 by justin808. -
[Pro] Doctor and the Node renderer name a patched release for superseded RSC prereleases: the error
for a rejectedreact-on-rails-rsc19.3.1-rc.x soak prerelease used to recommend stable 19.3.1 with React
19.3.0, which can keep vulnerable Flight 19.3.0. It now recommends 19.3.2 with React 19.3.1. The error for the
19.3.0-rc.4 pin that React on Rails 17.1.0 generated still recommends stable 19.3.0, now with React 19.2.9 so
its~19.2.8Flight range resolves the patched 19.2.9. Both errors now tell you to refresh the
lockfile so everyreact-server-dom-webpackcopy is patched for its React line.
Action required for upgraders: apps still on the 17.0react-on-rails-rsc19.2.1 set should move React and
React DOM to 19.2.9 together and refresh the lockfile so everyreact-server-dom-webpackcopy is patched: 19.2.9 or later on
19.2.x, or 19.3.1 or later on 19.3.x.
#5342 by justin808. -
create-react-on-rails-appno longer commits the Rails master key: The CLI runsrails new --skip-gitand then
writes.gitignoreitself, but Rails adds its key-file ignore rule only when.gitignorealready exists. When the
CLI rendered.gitignorefrom the installed Rails template, its first generated commit therefore tracked
config/master.key, the key that decryptsconfig/credentials.yml.enc. Only the CLI's bundled fallback
.gitignore, used when that template cannot be rendered, already ignored the key.
Generated apps now ignore/config/*.keyand/config/credentials/*.keybefore the first commit.
Action required for upgraders: an app generated bycreate-react-on-rails-app16.6.0-rc.0 through 17.2.1 may
have committedconfig/master.key. Run these steps from the app’s root directory, because Git resolves the
config/paths below from the current directory:- Untracking key files deletes them from each teammate’s working tree on their next pull and breaks any deploy
that reads them from the Git checkout. First back up every trackedconfig/*.keyandconfig/credentials/*.key
file outside the repository, for teammates to restore after that pull, and move such deploys to a
RAILS_MASTER_KEYenvironment variable or secret. - Add
/config/*.keyand/config/credentials/*.keyto the app’s.gitignore. Then rungit add .gitignoreand
git rm --cached --ignore-unmatch ':(glob)config/*.key' ':(glob)config/credentials/*.key', and commit both
changes together, so no key file those rules cover stays tracked. The:(glob)prefix keeps*from also
matching keys in otherconfig/subfolders. - Check the history in the app’s own checkout, not a fresh clone, so unpushed local branches are included. If
that checkout is shallow or single-branch,git fetch --unshallowalone misses keys that exist only on other
branches, so first rungit remote set-branches origin '*'and thengit fetch --unshallow origin(or
git fetch originif it is not shallow), using your remote’s name in place oforigin. Then run
git log --all --full-history --oneline -- ':(glob)config/*.key' ':(glob)config/credentials/*.key'. - If that lists a commit, rotate the credentials. Put each new key in the
RAILS_MASTER_KEYsecret of every
deploy that reads its credentials file and give it to teammates, then remove the old keys from the history
before publishing the repository. If a commit containing the key was ever pushed, including on a branch
deleted since, treat the key as compromised.
- Untracking key files deletes them from each teammate’s working tree on their next pull and breaks any deploy
Added
- [Pro] Async props on the RSC payload endpoint:
config.register_async_props("ComponentName", "ProviderClassName")registers the provider that supplies a
component's async props when the RSC payload endpoint renders it, soRSCRoute.refetch()works for
components that readgetReactOnRailsAsyncProp. Previously the built-in endpoint template rendered
every component without async props, so such a refetch failed unless the app shadowed that template.
The provider is called as.call(emit, props, controller). To build the async props in the payload
controller itself, overridersc_payload_async_props_block_override; it takes precedence over the
registry for the components it handles. The endpoint now also returns HTTP 400 whenpropsis a non-empty value that is not a string, such as bracket-notation
props[key]=value(previously HTTP 500), or is JSON that is not an object. Fixes
#5075.
#5091 by
AbanoubGhadban.
Improved
- [Pro] Uncached server renders no longer hash the render code: Pro now computes the MD5
request digest overjs_codeand its serialized props only when prerender caching needs it as a
cache key. Uncached renders send the Node Renderer a cheapComponent-pid-counterid in the same
URL segment, which the renderer does not use. The route shape is unchanged.
NodeRenderingPool.prepare_render_pathand.prepare_incremental_render_pathnow take only
render_options; drop thejs_codeargument if you call or override them.
#5223 by
justin808. Fixes
#4880. - [Pro] Node Renderer server bundles read globals faster: on Node 20.18+ and 22.8+, the
Node Renderer builds each bundle's VM context withvm.constants.DONT_CONTEXTIFY, so global
lookups inside the bundle skip V8's sandbox interceptors. Renders of three real application
bundles used about 20-25% less CPU in a local A/B. Rendered HTML and request isolation are
unchanged, and older Node versions keep the previous context.
#5313 by
alexeyr-ci2 and justin808.
Changed
-
[Pro] The Node renderer now requires Node.js 20.19 or later:
react-on-rails-pro-node-renderer
raisesengines.nodefrom>=18.19.0to>=20.19.0. Fresh installs already resolved Fastify 5
dependencies that declare Node 20 or later, and the renderer already exited at startup on Node 18.
The documented Node 18 workaround, overridingfastifyto^4.29.0, is no longer supported
because Fastify 4 is affected by
GHSA-p68q-wchp-6fh7.
Action required for upgraders: run the Node renderer on Node.js 20.19 or later, and remove any
fastify,@fastify/formbody, or@fastify/multipartoverrides or resolutions that pin Fastify 4. On Node.js 20 with npmengine-strict, a fresh install can still reject
cookie2.x, which needs Node.js 22; the Node renderer docs show an override. A new weekly CI
check fails when a fresh install resolves a package that rejects the advertised floor.
#5317 by
justin808. Part of
#5305. -
[Pro] React on Rails Pro adopts The ShakaStack License, version 1.0: ShakaStack Pro covers React on Rails Pro, ShakaPerf, and Inertia Rails SSR Cache for the whole organization with no size limit. React on Rails Pro remains free in development, test, CI, and staging when preparing an application before production. Releases before 17.3.0 keep the terms they shipped with.
#5346 by
sashakhar1. -
[Pro]
RSCRoutetakesrefas a regular prop instead offorwardRef: The public
<RSCRoute ref={…}>handle API andonRefetchErrorbehavior are unchanged, and no minimum React
version changes — the core package still supports React >= 16, and the RSC client path keeps its
existing React 19 floor (now enforced: rendering<RSCRoute>on older React fails fast with a
branded error naming the React >= 19 requirement and the version it found, instead of a cryptic
use is not a function, and CI re-runs the RSC client suite against real pinned React installs —
18.3.1 below the floor plus 19.0.x/19.1.x/19.2.x — with no mocks).useEffectEventwas deliberately not adopted to keep that floor. Calling
useEffectEvent,useFormStatus, oruseFormStatein a server component without'use client'
now gets the branded missing-directive diagnostic. Implements
#5030.
#5031 by
AbanoubGhadban.
Fixed
-
[Pro] TanStack Router loader errors now hydrate consistently after JSON transport. Production SSR and hydration use a generic error message, omitting private error details. Development preserves names, messages, and stacks, and warns about non-JSON loader data such as Date values.
#5340 by justin808. -
[Pro] Every published Pro JavaScript file carries the Pro license header: The compiled
registerServerComponent/client.jsandregisterServerComponent/server.jsinreact-on-rails-proshipped
without the header because TypeScript dropped it with an unused import. CI now packs both Pro npm packages and
fails if any packed.jsfile lacks the header. Fixes #5308.
#5316 by justin808. -
[Pro] Production refetch recovery handles streamed boundary errors. HTTP 200 Flight
responses whose root resolves before a descendant fails now restore the previous route content,
reportrefetchErrorandonRefetchError, and keep Retry available. Restoring content can remount
descendant client components and reset their local state. Incomplete records are classified as failed
streams and restore prior content even when the decoded root never throws. Scalar return values stay
unchanged. Initial-load
render failures still propagate to the outer error boundary. Fixes
#5078.
#5135 by
Justin Gordon. -
Server rendering works when Bun is installed: ExecJS 2.9+ picks Bun ahead of Node.js, and Bun fails to
evaluate some server bundles ("Expected CommonJS module to have a function wrapper"), so a freshly generated
--standardapp returned HTTP 500 on its server-rendered page. When ExecJS autodetects Bun and Node.js is
installed, React on Rails now renders with Node.js.ExecJS.runtimeitself is unchanged for other ExecJS users,
and an explicitEXECJS_RUNTIMEstill wins; setEXECJS_RUNTIME=Bunto force Bun (assigning
ExecJS.runtimein Ruby code is treated like autodetection).react_on_rails:doctorreports the runtime server
rendering uses and warns when it is Bun. Pro apps that render through the Node Renderer change only on their ExecJS
fallback path.
Fixes #5288.
#5319 by justin808. -
[Pro] TanStack Router SSR now passes
dehydrateoutput tohydrate:react-on-rails-pro/tanstack-router
now calls the router'sdehydrateoption once on the server afterrouter.load(), and passes its result to the
hydrateoption on the client. Previously the helper probed arouter.dehydrate()method that TanStack Router
does not have, sohydratealways receivedundefinedand a TanStack Query cache or other external state never
reached the client. The value travels as JSON, soDate,Error, andMapvalues lose their types. The helper
no longer calls customrouter.dehydrate()orrouter.hydrate()methods.
Fixes #5126.
#5312 by justin808. -
npm packages no longer ship
sourceMappingURLpointers to missing.mapfiles: The published
create-react-on-rails-appandreact-on-rails-pro-node-renderer.jsand.d.tsfiles, and the.d.tsfiles in
react-on-railsandreact-on-rails-pro, ended with//# sourceMappingURL=comments for maps the packages never
shipped.node --enable-source-maps, debuggers, and error trackers that followed them looked for a file that
isn't there. The packages'tscbuilds no longer emit source or declaration maps, and CI now packs all four
packages and fails on any dangling pointer. Fixes #5307.
#5321 by justin808. -
bin/devpack generation keeps variables thatbin/devsets after Bundler loads: The
react_on_rails:generate_packschild now receives every variable that changed since Bundler
loaded, and loses any that were deleted. Bundler's own variables stay out, so the child still
runs unbundled. PreviouslyBundler.with_unbundled_envreset the child to Bundler's startup
snapshot. An initializer that needed a variable set afterrequire "bundler/setup", or under
bundle exec bin/dev, then failed at "Generating packs". Fixes
#5297.
#5320 by
justin808. -
Components inside a Turbo Frame now mount after a frame navigation: With
turbo: true, thereact-on-rails
package now handlesturbo:frame-render. It unmounts the components the frame render removed and mounts the ones
in the new frame content. Components outside the frame stay mounted.
Previously the open-source package never mounted frame content loaded by navigation and leaked the
replaced frame's React roots. Fixes #5128.
#5220 by justin808. -
[Pro] Turbo Frame navigation releases the replaced frame's React roots: With
turbo: true, the
react-on-rails-propackage now handlesturbo:frame-renderand unmounts the components the frame render removed.
Components outside the frame stay mounted, and the new frame content still mounts through each component's inline
script. Previously the replaced roots stayed mounted until the next full Turbo page visit.
Fixes #5128.
#5227 by justin808. -
A failed load of
react-dom/clientis reported instead of swallowed: With React 18 or later, when
react-dom/clientexists but one of its own dependencies fails to load, React on Rails now rethrows that
error when the bundle loads. Previously it was discarded and surfaced later as
reactDomClient.hydrateRoot is not a function, or not at all in a server bundle. React 16 and 17 apps are
unaffected: a missingreact-dom/clientstill falls back toreact-dom. The optional-module behavior
is preserved with webpack and Rspack.
RSC bundles avoid the client-only import. Action required for upgraders: if a server bundle now
fails to load, restore or bundle the missing dependency named in the original error.
Fixes #5180.
#5181 by justin808. -
[Pro] Generated Pro apps ignore the Node renderer bundle cache:
react_on_rails:install --proand--rsc,
including the default Pro and--rscsetups ofcreate-react-on-rails-app, now add.node-renderer-bundlesand its preseed lock/snapshot siblings to
.gitignore, so the server bundles that the generatedrenderer/node-renderer.jscaches there stay out of commits.
#5182 by justin808. -
Doctor recognizes more static watcher commands: With a shared output path and a dev-server
Procfile.dev,
rake react_on_rails:doctorexited 1 reportingProcfile.dev-static-assetsmissing unless that file contained the
exact textbin/shakapacker --watch. It now accepts--watchor-wonbin/shakapackeror the generated
bin/shakapacker-watch, and ignores commented-out commands.
#5304 by justin808. -
Single render results reject incomplete trailing records: Server rendering now raises
ReactOnRails::JsonParseErrorwhen a complete result is followed by a partial length-prefixed record, instead
of silently discarding the remainder.
Valid producer responses and warning-only streaming flush behavior are unchanged.
#5206 by justin808. -
[Pro] Streams reject non-object metadata: The TypeScript length-prefixed parser now rejects JSON
null, arrays, and scalar metadata before yielding a chunk, matching Ruby's existing object requirement.
Valid object metadata, control frames, and blank or CRLF separators retain their behavior.
#5206 by justin808.