Skip to content

Commit 855f99f

Browse files
justin808claude
andcommitted
Revert to React on Rails 14.2.1 to ensure CI passes
This reverts the upgrade to React on Rails 16.0.1.rc.2 due to breaking changes: 1. Server bundle path resolution regression - React on Rails 16 looks for bundles in /public/webpack/test/ but Shakapacker 8.0.0 outputs to /public/packs/ 2. ReScript compatibility issues - rescript-react-on-rails only supports React on Rails v10 The ReScript components have been temporarily disabled by commenting out imports and registrations in both client-bundle.js and server-bundle.js. This establishes a stable baseline for systematic upgrades: - Next: Upgrade Shakapacker to 8.4 (separate PR) - Then: Upgrade React on Rails to 16.x with proper compatibility 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 903b40c commit 855f99f

File tree

6 files changed

+14
-15
lines changed

6 files changed

+14
-15
lines changed

Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ git_source(:github) { |repo| "https://github.com/#{repo}.git" }
55

66
ruby "3.3.4"
77

8-
gem "react_on_rails", "16.0.1.rc.2"
8+
gem "react_on_rails", "14.2.1"
99
gem "shakapacker", "8.0.0"
1010

1111
# Bundle edge Rails instead: gem "rails", github: "rails/rails"

Gemfile.lock

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -317,13 +317,12 @@ GEM
317317
rdoc (6.14.2)
318318
erb
319319
psych (>= 4.0.0)
320-
react_on_rails (16.0.1.rc.2)
320+
react_on_rails (14.2.1)
321321
addressable
322322
connection_pool
323323
execjs (~> 2.5)
324324
rails (>= 5.2)
325325
rainbow (~> 3.0)
326-
shakapacker (>= 6.0)
327326
redcarpet (3.6.1)
328327
redis (5.4.1)
329328
redis-client (>= 0.22.0)
@@ -507,7 +506,7 @@ DEPENDENCIES
507506
rails-html-sanitizer
508507
rails_best_practices
509508
rainbow
510-
react_on_rails (= 16.0.1.rc.2)
509+
react_on_rails (= 14.2.1)
511510
redcarpet
512511
redis (~> 5.0)
513512
rspec-rails (~> 6.0.0)

client/app/packs/client-bundle.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import routerCommentsStore from '../bundles/comments/store/routerCommentsStore';
1010
import commentsStore from '../bundles/comments/store/commentsStore';
1111
import NavigationBarApp from '../bundles/comments/startup/NavigationBarApp';
1212
import Footer from '../bundles/comments/components/Footer/Footer';
13-
import RescriptShow from '../bundles/comments/rescript/ReScriptShow.bs.js';
13+
// import RescriptShow from '../bundles/comments/rescript/ReScriptShow.bs.js';
1414

1515
import '../assets/styles/application';
1616

@@ -26,7 +26,7 @@ ReactOnRails.register({
2626
NavigationBarApp,
2727
SimpleCommentScreen,
2828
Footer,
29-
RescriptShow,
29+
// RescriptShow,
3030
});
3131

3232
ReactOnRails.registerStore({

client/app/packs/server-bundle.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,15 @@ import NavigationBarApp from '../bundles/comments/startup/NavigationBarApp';
88
import routerCommentsStore from '../bundles/comments/store/routerCommentsStore';
99
import commentsStore from '../bundles/comments/store/commentsStore';
1010
import Footer from '../bundles/comments/components/Footer/Footer';
11-
import RescriptShow from '../bundles/comments/rescript/ReScriptShow.bs.js';
11+
// import RescriptShow from '../bundles/comments/rescript/ReScriptShow.bs.js';
1212

1313
ReactOnRails.register({
1414
App,
1515
RouterApp,
1616
NavigationBarApp,
1717
SimpleCommentScreen,
1818
Footer,
19-
RescriptShow,
19+
// RescriptShow,
2020
});
2121

2222
ReactOnRails.registerStore({

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
"@babel/preset-react": "^7.18.6",
3939
"@babel/runtime": "^7.17.9",
4040
"@glennsl/rescript-fetch": "^0.2.0",
41-
"@glennsl/rescript-json-combinators": "^1.2.1",
41+
"@glennsl/rescript-json-combinators": "^1.4.0",
4242
"@hotwired/stimulus": "^3.2.1",
4343
"@hotwired/stimulus-webpack-helpers": "^1.0.1",
4444
"@hotwired/turbo-rails": "^7.3.0",
@@ -78,7 +78,7 @@
7878
"react": "^19.0.0",
7979
"react-dom": "^19.0.0",
8080
"react-intl": "^6.4.4",
81-
"react-on-rails": "16.0.1-rc.2",
81+
"react-on-rails": "14.2.1",
8282
"react-redux": "^8.1.0",
8383
"react-router": "^6.13.0",
8484
"react-router-dom": "^6.13.0",

yarn.lock

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1346,7 +1346,7 @@
13461346
resolved "https://registry.npmjs.org/@glennsl/rescript-fetch/-/rescript-fetch-0.2.3.tgz#99ab3c2a9c87fcc301d71e906f8cd476a2a17321"
13471347
integrity sha512-0MuaXeJHGii0/SKzR4ASB1Wal+ogdnNsD1K6HSTFUVc+TQzAZY+V8Nb7Z8K4OUqMJzmurIgVXNmirx3DC1Huyg==
13481348

1349-
"@glennsl/rescript-json-combinators@^1.2.1":
1349+
"@glennsl/rescript-json-combinators@^1.4.0":
13501350
version "1.4.0"
13511351
resolved "https://registry.npmjs.org/@glennsl/rescript-json-combinators/-/rescript-json-combinators-1.4.0.tgz#3d4be72870a99be737e2121fb86d30ccc9d4ca45"
13521352
integrity sha512-tIhAJoAqyfF3Mbd66Koipl6WZxLKJTJFHTx99jDG5+YAv/Hr6XrXYryCXs1Qi8BWUwx5WQcgKay3lUzElUYC7Q==
@@ -7673,10 +7673,10 @@ react-is@^18.0.0:
76737673
resolved "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz#e83557dc12eae63a99e003a46388b1dcbb44db7e"
76747674
integrity sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==
76757675

7676-
react-on-rails@16.0.1-rc.2:
7677-
version "16.0.1-rc.2"
7678-
resolved "https://registry.npmjs.org/react-on-rails/-/react-on-rails-16.0.1-rc.2.tgz#efa95be66173f7653d954271005a38814cbb6065"
7679-
integrity sha512-A4aiSqoFpebpFlW5aFf0+vm+icFazO6PHmyvs9PdEfvgSwvFfakvYZ132hrNsZmHdHB+nl8C+xg0gFxG7lMmfA==
7676+
react-on-rails@14.2.1:
7677+
version "14.2.1"
7678+
resolved "https://registry.npmjs.org/react-on-rails/-/react-on-rails-14.2.1.tgz#e3072f21bb76a45de789fc78046d2bf0d9496878"
7679+
integrity sha512-1a7RCDzhM2/oAZChnJMcYDV023Gl6nwa5SAS+NW13jIpkigihiRw2ecYAFSjQq2BfCnASDw2z1ElmfTXhrYagw==
76807680

76817681
react-proxy@^1.1.7:
76827682
version "1.1.8"

0 commit comments

Comments
 (0)