-
-
Notifications
You must be signed in to change notification settings - Fork 638
Migrate from Yarn Classic to pnpm #2121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
WalkthroughThis pull request migrates the repository from Yarn Classic to pnpm: updates CI workflows, root and package manifests, build/rake scripts, pre-commit hooks, tooling configs, and documentation; adds pnpm workspace and .npmrc settings; converts workspace dependency references to Changes
Sequence Diagram(s)sequenceDiagram
actor Dev as Developer
participant Local as Local Repo
participant PNPM as pnpm (local manager)
participant CI as GitHub Actions
participant PackageB as Dependent Package
rect rgba(220,240,255,0.8)
Note over Dev,PackageB: Before (Yarn Classic + yalc)
Dev->>Local: yarn install
Dev->>Local: modify PackageA
Dev->>Local: yarn yalc publish
Local->>PackageB: manual yalc link
PackageB->>PackageB: uses published artifact (manual cycle)
end
rect rgba(220,255,230,0.8)
Note over Dev,PackageB: After (pnpm workspaces)
Dev->>Local: pnpm install
PNPM->>Local: resolve `workspace:*` → symlink
Dev->>Local: modify PackageA
PackageB->>PNPM: uses workspace symlink (immediate)
PackageB->>PackageB: uses local changes (no publish)
end
rect rgba(255,250,220,0.6)
Note over CI,PNPM: CI flow (changed)
CI->>PNPM: setup pnpm action & pnpm install
CI->>PNPM: derive pnpm store path -> cache pnpm-store
CI->>PNPM: run pnpm --filter / -r build/test
end
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Areas to focus during review:
Possibly related issues
Possibly related PRs
Suggested reviewers
Poem
Pre-merge checks and finishing touches✅ Passed checks (5 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used📓 Path-based instructions (1)**/*📄 CodeRabbit inference engine (CLAUDE.md)
Files:
🧠 Learnings (10)📓 Common learnings📚 Learning: 2025-11-25T04:54:35.286ZApplied to files:
📚 Learning: 2025-04-26T21:55:55.874ZApplied to files:
📚 Learning: 2025-11-25T04:54:35.286ZApplied to files:
📚 Learning: 2025-11-25T04:54:35.286ZApplied to files:
📚 Learning: 2025-02-12T16:38:06.537ZApplied to files:
📚 Learning: 2025-09-16T08:01:11.146ZApplied to files:
📚 Learning: 2025-11-25T04:54:35.286ZApplied to files:
📚 Learning: 2025-07-08T05:57:29.630ZApplied to files:
📚 Learning: 2025-11-25T04:54:35.286ZApplied to files:
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (9)
🔇 Additional comments (1)
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 |
Code Review: Yarn Classic to pnpm MigrationThis is a well-executed migration from Yarn Classic to pnpm. The PR is comprehensive and follows best practices. Here is my detailed feedback: Critical Issue FoundCRITICAL: Release Task Still Uses Yarn (Priority: HIGH) rakelib/release.rake lines 261, 266, 279 still use yarn workspace and yarn publish commands. This will cause the release process to fail completely. Lines that need fixing:
These need to be updated to use pnpm commands:
Strengths
Testing RequirementsPer CLAUDE.md guidelines, these tests must be verified:
PR description shows install and build tested, but yalc workflow and CI need verification. Minor Suggestions
SummaryMust fix before merge: Release rake task still uses yarn commands Great work overall! Once the release rake task is fixed and testing verified, this will be ready to merge. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
CONTRIBUTING.md (1)
603-606: Convert npm commands to pnpm in testing examples for consistency with the migration.Lines 603-606 and 623-627 still use
npm run build,npm pack, andnpm installwhile the rest of the file has been migrated to pnpm. SincepackageManageris set to[email protected], these should be updated:
- Line 603:
npm run build→pnpm run build- Line 603:
npx yalc publish→npx yalc publish(remains unchanged; yalc is independent)- Line 606:
npx yalc push→npx yalc push(orpnpm exec yalc pushfor consistency)- Line 606:
npm install→pnpm install- Line 624:
npm run build→pnpm run build- Line 625:
npm pack→pnpm pack- Line 627:
npm install ../path/to/...→pnpm install ../path/to/...
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (6)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yamlreact_on_rails_pro/spec/dummy/yarn.lockis excluded by!**/yarn.lock,!**/*.lockreact_on_rails_pro/spec/execjs-compatible-dummy/yarn.lockis excluded by!**/yarn.lock,!**/*.lockreact_on_rails_pro/yarn.lockis excluded by!**/yarn.lock,!**/*.lockspec/dummy/yarn.lockis excluded by!**/yarn.lock,!**/*.lockyarn.lockis excluded by!**/yarn.lock,!**/*.lock
📒 Files selected for processing (29)
.claude/docs/pr-splitting-strategy.md(0 hunks).claude/docs/testing-build-scripts.md(7 hunks).github/workflows/examples.yml(2 hunks).github/workflows/gem-tests.yml(0 hunks).github/workflows/integration-tests.yml(5 hunks).github/workflows/lint-js-and-ruby.yml(2 hunks).github/workflows/package-js-tests.yml(1 hunks).github/workflows/playwright.yml(2 hunks).github/workflows/pro-integration-tests.yml(13 hunks).github/workflows/pro-lint.yml(4 hunks).github/workflows/pro-test-package-and-gem.yml(5 hunks).npmrc(1 hunks)CHANGELOG.md(0 hunks)CLAUDE.md(8 hunks)CODING_AGENTS.md(0 hunks)CONTRIBUTING.md(16 hunks)TODO.md(0 hunks)package.json(2 hunks)packages/react-on-rails-pro-node-renderer/package.json(3 hunks)packages/react-on-rails-pro/package.json(2 hunks)packages/react-on-rails/package.json(1 hunks)pnpm-workspace.yaml(1 hunks)rakelib/dummy_apps.rake(1 hunks)rakelib/lint.rake(3 hunks)rakelib/node_package.rake(1 hunks)rakelib/run_rspec.rake(1 hunks)react_on_rails_pro/spec/dummy/package.json(2 hunks)react_on_rails_pro/spec/execjs-compatible-dummy/package.json(2 hunks)spec/dummy/package.json(1 hunks)
💤 Files with no reviewable changes (5)
- TODO.md
- CHANGELOG.md
- .github/workflows/gem-tests.yml
- .claude/docs/pr-splitting-strategy.md
- CODING_AGENTS.md
🧰 Additional context used
📓 Path-based instructions (5)
**/*
📄 CodeRabbit inference engine (CLAUDE.md)
ALWAYS ensure files end with a newline character before every commit/push
Files:
packages/react-on-rails/package.jsonCONTRIBUTING.mdrakelib/run_rspec.rakepackage.jsonrakelib/node_package.rakerakelib/dummy_apps.rakerakelib/lint.rakepackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonpnpm-workspace.yamlpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
**/*.{js,ts,jsx,tsx,json,md,yml,yaml}
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.{js,ts,jsx,tsx,json,md,yml,yaml}: ALWAYS let Prettier and RuboCop handle ALL formatting - never manually format code
Install Prettier with auto-format capability via git hooks for automatic formatting on changed files before each commit
Files:
packages/react-on-rails/package.jsonCONTRIBUTING.mdpackage.jsonpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonpnpm-workspace.yamlpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
package.json
📄 CodeRabbit inference engine (CLAUDE.md)
After resolving merge conflicts affecting
package.json, verify no hardcoded paths need updating
Files:
package.json
react_on_rails_pro/**/*.{js,ts,jsx,tsx,json,md,yml,yaml}
📄 CodeRabbit inference engine (CLAUDE.md)
The
react_on_rails_pro/directory has its own Prettier/ESLint configuration; both root and Pro directories are linted separately by CI
Files:
react_on_rails_pro/spec/dummy/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.json
spec/dummy/**
📄 CodeRabbit inference engine (CLAUDE.md)
The dummy app in
spec/dummy/is a full Rails app for integration testing of the React on Rails gem
Files:
spec/dummy/package.json
🧠 Learnings (44)
📓 Common learnings
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to package-scripts.yml : After resolving merge conflicts affecting `package-scripts.yml`, verify no hardcoded paths need updating and test with `yarn run prepack`
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Never use `npm` commands; only use equivalent Yarn Classic commands for package management
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to package-scripts.yml : After resolving merge conflicts affecting `package-scripts.yml`, verify no hardcoded paths need updating and test with `yarn run prepack`
Applied to files:
.github/workflows/integration-tests.ymlpackages/react-on-rails/package.jsonCONTRIBUTING.mdrakelib/run_rspec.rake.claude/docs/testing-build-scripts.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.ymlpackage.jsonrakelib/node_package.rake.github/workflows/pro-lint.yml.github/workflows/package-js-tests.ymlrakelib/dummy_apps.rake.github/workflows/examples.ymlrakelib/lint.rake.github/workflows/pro-integration-tests.yml.github/workflows/playwright.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonpnpm-workspace.yamlpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*webpack* : After resolving merge conflicts affecting webpack configs, verify hardcoded paths and test affected scripts
Applied to files:
.github/workflows/integration-tests.yml.claude/docs/testing-build-scripts.md.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-lint.yml.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Run `yarn playwright install --with-deps` in spec/dummy to install Playwright browsers before running E2E tests
Applied to files:
.github/workflows/integration-tests.ymlCONTRIBUTING.md.claude/docs/testing-build-scripts.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-lint.ymlrakelib/dummy_apps.rake.github/workflows/examples.yml.github/workflows/pro-integration-tests.yml.github/workflows/playwright.ymlreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Use `bin/ci-switch-config` to switch between CI configurations (Latest: Ruby 3.4, Node 22, Shakapacker 9.3.0, React 19 vs Minimum: Ruby 3.2, Node 20, Shakapacker 8.2.0, React 18)
Applied to files:
.github/workflows/integration-tests.ymlCONTRIBUTING.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-lint.yml.github/workflows/examples.yml.github/workflows/pro-integration-tests.ymlCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/dummy/** : The dummy app in `spec/dummy/` is a full Rails app for integration testing of the React on Rails gem
Applied to files:
.github/workflows/integration-tests.ymlCONTRIBUTING.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/pro-lint.ymlrakelib/dummy_apps.rake.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to react_on_rails_pro/sig/**/*.rbs : Validate Pro package RBS signatures with `cd react_on_rails_pro && bundle exec rake rbs:validate`
Applied to files:
.github/workflows/integration-tests.ymlCONTRIBUTING.mdrakelib/run_rspec.rake.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-lint.ymlrakelib/dummy_apps.rake.github/workflows/examples.yml.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/dummy/e2e/playwright/**/*.spec.js : Write Playwright E2E tests in `spec/dummy/e2e/playwright/e2e/` directory using the `cypress-on-rails` gem helpers for Rails integration
Applied to files:
.github/workflows/integration-tests.ymlCONTRIBUTING.mdrakelib/run_rspec.rake.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-lint.ymlrakelib/dummy_apps.rake.github/workflows/pro-integration-tests.yml.github/workflows/playwright.ymlreact_on_rails_pro/spec/dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to packages/react-on-rails/src/**/*.{ts,tsx,js,jsx} : TypeScript in `packages/react-on-rails/src/` compiles to JavaScript in `packages/react-on-rails/lib/` during build process
Applied to files:
.github/workflows/integration-tests.ymlpackages/react-on-rails/package.json.npmrcCONTRIBUTING.mdrakelib/run_rspec.rake.claude/docs/testing-build-scripts.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.ymlpackage.json.github/workflows/pro-lint.yml.github/workflows/examples.yml.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonpnpm-workspace.yamlpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/dummy/e2e/playwright/app_commands/**/*.rb : Create custom Rails helper commands for Playwright tests in `spec/dummy/e2e/playwright/app_commands/` directory
Applied to files:
.github/workflows/integration-tests.ymlCONTRIBUTING.mdrakelib/run_rspec.rake.github/workflows/pro-test-package-and-gem.yml.github/workflows/pro-lint.ymlrakelib/dummy_apps.rakerakelib/lint.rake.github/workflows/pro-integration-tests.yml.github/workflows/playwright.ymlreact_on_rails_pro/spec/dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Exclude `/coverage`, `/tmp`, `/gen-examples`, `/packages/react-on-rails/lib`, `/node_modules`, `/spec/dummy/node_modules`, `/spec/dummy/tmp`, `/spec/dummy/app/assets/webpack`, `/spec/dummy/log`, `/spec/dummy/e2e/playwright-report`, `/spec/dummy/test-results` directories in IDE configuration to prevent slowdowns
Applied to files:
.github/workflows/integration-tests.yml.claude/docs/testing-build-scripts.md.github/workflows/lint-js-and-ruby.ymlpackage.json.github/workflows/pro-lint.yml.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonpnpm-workspace.yamlCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Use `yalc` for local development when testing React on Rails with external applications
Applied to files:
.github/workflows/integration-tests.ymlpackages/react-on-rails/package.json.npmrcCONTRIBUTING.md.claude/docs/testing-build-scripts.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.ymlpackage.jsonrakelib/node_package.rake.github/workflows/pro-lint.ymlrakelib/dummy_apps.rake.github/workflows/examples.yml.github/workflows/pro-integration-tests.yml.github/workflows/playwright.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-01-23T18:20:45.824Z
Learnt from: alexeyr-ci
Repo: shakacode/react_on_rails PR: 1687
File: spec/dummy/package.json:0-0
Timestamp: 2025-01-23T18:20:45.824Z
Learning: When adding or updating dependencies in spec/dummy/package.json, maintain version consistency with other package.json files in the codebase to avoid potential version conflicts.
Applied to files:
.github/workflows/integration-tests.ymlpackages/react-on-rails/package.jsonrakelib/run_rspec.rake.claude/docs/testing-build-scripts.md.github/workflows/pro-test-package-and-gem.ymlpackage.jsonrakelib/dummy_apps.rake.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Never use `npm` commands; only use equivalent Yarn Classic commands for package management
Applied to files:
.github/workflows/integration-tests.ymlpackages/react-on-rails/package.jsonCONTRIBUTING.md.claude/docs/testing-build-scripts.md.github/workflows/pro-test-package-and-gem.ymlrakelib/node_package.rake.github/workflows/examples.ymlrakelib/lint.rakepackages/react-on-rails-pro-node-renderer/package.jsonspec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to /CHANGELOG_PRO.md : Update `/CHANGELOG_PRO.md` for Pro-only features, bug fixes, and changes specific to the react_on_rails_pro package
Applied to files:
packages/react-on-rails/package.jsonCONTRIBUTING.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/pro-lint.yml.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to react_on_rails_pro/**/*.{js,ts,jsx,tsx,json,md,yml,yaml} : The `react_on_rails_pro/` directory has its own Prettier/ESLint configuration; both root and Pro directories are linted separately by CI
Applied to files:
packages/react-on-rails/package.json.npmrcCONTRIBUTING.md.claude/docs/testing-build-scripts.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.ymlpackage.json.github/workflows/pro-lint.ymlrakelib/dummy_apps.rakerakelib/lint.rake.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-02-12T16:38:06.537Z
Learnt from: Romex91
Repo: shakacode/react_on_rails PR: 1697
File: package-scripts.yml:28-28
Timestamp: 2025-02-12T16:38:06.537Z
Learning: The file `node_package/lib/ReactOnRails.full.js` is autogenerated during the build process and should not be present in the repository.
Applied to files:
packages/react-on-rails/package.json.npmrcCONTRIBUTING.mdpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonspec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to package.json : After resolving merge conflicts affecting `package.json`, verify no hardcoded paths need updating
Applied to files:
packages/react-on-rails/package.json.claude/docs/testing-build-scripts.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/lint-js-and-ruby.ymlpackage.json.github/workflows/pro-lint.yml.github/workflows/package-js-tests.yml.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonCLAUDE.md
📚 Learning: 2025-04-26T21:55:55.874Z
Learnt from: alexeyr-ci2
Repo: shakacode/react_on_rails PR: 1732
File: spec/dummy/client/app-react16/startup/ReduxSharedStoreApp.client.jsx:40-44
Timestamp: 2025-04-26T21:55:55.874Z
Learning: In the react_on_rails project, files under `app-react16` directories are copied/moved to corresponding `/app` directories during the conversion process (removing the `-react16` suffix), which affects their relative import paths at runtime.
Applied to files:
packages/react-on-rails/package.json.npmrcCONTRIBUTING.mdpackages/react-on-rails-pro-node-renderer/package.jsonreact_on_rails_pro/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.json
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.{js,ts,jsx,tsx,json,md,yml,yaml} : Install Prettier with auto-format capability via git hooks for automatic formatting on changed files before each commit
Applied to files:
packages/react-on-rails/package.jsonCONTRIBUTING.md.claude/docs/testing-build-scripts.mdpackage.json.github/workflows/pro-lint.ymlrakelib/lint.rakepackages/react-on-rails-pro-node-renderer/package.jsonpackages/react-on-rails-pro/package.jsonCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.{js,ts,jsx,tsx,json,md,yml,yaml} : ALWAYS let Prettier and RuboCop handle ALL formatting - never manually format code
Applied to files:
packages/react-on-rails/package.jsonCONTRIBUTING.md.claude/docs/testing-build-scripts.md.github/workflows/lint-js-and-ruby.ymlpackage.json.github/workflows/pro-lint.ymlrakelib/lint.rakepackages/react-on-rails-pro-node-renderer/package.jsonCLAUDE.md
📚 Learning: 2025-09-16T08:01:11.146Z
Learnt from: justin808
Repo: shakacode/react_on_rails PR: 1770
File: lib/generators/react_on_rails/templates/base/base/app/javascript/src/HelloWorld/ror_components/HelloWorld.client.jsx:2-2
Timestamp: 2025-09-16T08:01:11.146Z
Learning: React on Rails uses webpack CSS Modules configuration with namedExports: true, which requires the import syntax `import * as style from './file.module.css'` rather than the default export pattern. This configuration enables better tree shaking and bundle size optimization for CSS modules.
Applied to files:
.npmrcCONTRIBUTING.mdpackages/react-on-rails-pro-node-renderer/package.jsonpackages/react-on-rails-pro/package.jsonreact_on_rails_pro/spec/execjs-compatible-dummy/package.json
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to /CHANGELOG.md : Do NOT add changelog entries for linting, formatting, refactoring, tests, or documentation-only fixes
Applied to files:
CONTRIBUTING.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to /CHANGELOG_PRO.md : Do NOT add changelog entries for linting, formatting, refactoring, tests, or documentation-only fixes in the Pro changelog
Applied to files:
CONTRIBUTING.md.github/workflows/pro-lint.yml.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to /CHANGELOG.md : Update `/CHANGELOG.md` for open-source features, bug fixes, breaking changes, deprecations, and performance improvements
Applied to files:
CONTRIBUTING.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to lib/generators/react_on_rails/**/*.rb : Generators in `lib/generators/react_on_rails/` run in host app context during setup and can assume Rails app structure
Applied to files:
CONTRIBUTING.mdrakelib/dummy_apps.rakepackages/react-on-rails-pro-node-renderer/package.jsonpackages/react-on-rails-pro/package.json
📚 Learning: 2025-07-08T05:57:29.630Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1745
File: node_package/src/RSCRequestTracker.ts:8-14
Timestamp: 2025-07-08T05:57:29.630Z
Learning: The global `generateRSCPayload` function in React on Rails Pro (RORP) is provided by the framework during rendering requests, not implemented in application code. The `declare global` statements are used to document the expected interface that RORP will inject at runtime.
Applied to files:
CONTRIBUTING.md
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Use `yarn test:e2e` to run Playwright tests; Rails server auto-starts on port 5017
Applied to files:
CONTRIBUTING.mdrakelib/run_rspec.rake.github/workflows/pro-test-package-and-gem.ymlpackage.json.github/workflows/pro-lint.yml.github/workflows/pro-integration-tests.yml.github/workflows/playwright.ymlreact_on_rails_pro/spec/dummy/package.jsonpackages/react-on-rails-pro/package.jsonCLAUDE.md
📚 Learning: 2025-10-23T17:22:01.074Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1875
File: lib/react_on_rails/utils.rb:112-124
Timestamp: 2025-10-23T17:22:01.074Z
Learning: In React on Rails, when Pro is installed but not licensed, the intended behavior is to raise an error on boot. The `react_on_rails_pro?` method validates licenses and should raise errors early (including during path resolution in methods like `server_bundle?`) to enforce licensing requirements rather than failing later with obscure errors.
Applied to files:
CONTRIBUTING.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/dummy/TESTING_LOCALLY.md : Refer to `spec/dummy/TESTING_LOCALLY.md` for local testing tips and known issues when testing the dummy Rails app
Applied to files:
CONTRIBUTING.md.github/workflows/pro-test-package-and-gem.yml.github/workflows/pro-integration-tests.ymlCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.{js,ts,jsx,tsx} : Install ESLint with auto-fix capability via git hooks for automatic linting on changed files before each commit
Applied to files:
CONTRIBUTING.md.claude/docs/testing-build-scripts.mdpackage.jsonrakelib/lint.rakeCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.rb : ALWAYS run `bundle exec rubocop` and fix ALL violations before every commit/push
Applied to files:
CONTRIBUTING.mdrakelib/run_rspec.rake.claude/docs/testing-build-scripts.md.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-lint.ymlrakelib/lint.rakeCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Run `bundle exec rubocop` to fix ALL violations before pushing (mandatory pre-push requirement)
Applied to files:
CONTRIBUTING.mdrakelib/run_rspec.rake.github/workflows/pro-lint.ymlrakelib/lint.rakeCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.rb : Install RuboCop with auto-fix capability via git hooks for automatic linting on changed files before each commit
Applied to files:
CONTRIBUTING.mdrakelib/lint.rakeCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to lib/react_on_rails/**/*.rb : When creating new Ruby files in `lib/react_on_rails/`, add corresponding RBS type signatures and include in Steepfile for type checking
Applied to files:
CONTRIBUTING.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.rb : ALWAYS let RuboCop handle ALL formatting for Ruby files - never manually format code
Applied to files:
CONTRIBUTING.mdrakelib/lint.rake
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: When resolving merge conflicts, follow exact sequence: resolve conflicts, verify file paths, auto-fix formatting with `rake autofix`, test critical scripts, then continue merge
Applied to files:
CONTRIBUTING.md.claude/docs/testing-build-scripts.mdrakelib/lint.rakeCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/**/*.rb : Use `bin/ci-run-failed-specs` to run only failing RSpec examples from GitHub Actions output
Applied to files:
.github/workflows/lint-js-and-ruby.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Validate RBS type signatures with `bundle exec rake rbs:validate` before committing type-checked code
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Run `bundle exec rake rbs:steep` to type-check Ruby code with Steep against RBS signatures
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to lib/react_on_rails/engine.rb : In the Engine class, do not use `rake_tasks` block to load rake files from `lib/tasks/` as Rails::Engine loads them automatically, causing duplicate execution
Applied to files:
rakelib/dummy_apps.rake
📚 Learning: 2025-02-13T19:09:15.991Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: node_package/src/RSCWebpackLoader.ts:0-0
Timestamp: 2025-02-13T19:09:15.991Z
Learning: In React Server Components webpack loader, using `new Function('return import("react-server-dom-webpack/node-loader")')()` is necessary as a workaround to bypass TypeScript compilation issues with direct dynamic imports.
Applied to files:
packages/react-on-rails-pro/package.jsonCLAUDE.md
📚 Learning: 2024-12-12T13:07:09.929Z
Learnt from: alexeyr-ci
Repo: shakacode/react_on_rails PR: 1644
File: node_package/src/ReactOnRailsRSC.ts:87-87
Timestamp: 2024-12-12T13:07:09.929Z
Learning: When handling errors in 'node_package/src/ReactOnRailsRSC.ts', include the error stack in error messages in development and test environments to aid debugging.
Applied to files:
packages/react-on-rails-pro/package.json
📚 Learning: 2025-02-13T16:50:47.848Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: node_package/src/clientStartup.ts:18-21
Timestamp: 2025-02-13T16:50:47.848Z
Learning: In the react_on_rails module, the `reactOnRailsPageUnloaded` function in clientStartup.ts is intentionally kept private as it's only used internally as a callback for `onPageUnloaded`.
Applied to files:
packages/react-on-rails-pro/package.json
🪛 LanguageTool
CONTRIBUTING.md
[uncategorized] ~22-~22: “React” is a proper noun and needs to be capitalized.
Context: ...sites Note for users: End users of react_on_rails can continue using their prefe...
(A_GOOGLE)
[uncategorized] ~22-~22: “React” is a proper noun and needs to be capitalized.
Context: ...low are for contributors working on the react_on_rails codebase itself. - [Yalc](htt...
(A_GOOGLE)
[style] ~310-~310: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...figs, then you need to restart Foreman. If you change the JS code for react-on-rai...
(ENGLISH_WORD_REPEAT_BEGINNING_RULE)
🪛 markdownlint-cli2 (0.18.1)
.claude/docs/testing-build-scripts.md
114-114: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: rspec-package-tests (3.4, latest)
- GitHub Check: claude-review
🔇 Additional comments (47)
CONTRIBUTING.md (1)
1-883: Ensure file ends with newline character.Per the coding guidelines, all files must end with a newline before commit.
rakelib/run_rspec.rake (1)
113-116: LGTM! Rake task correctly updated for pnpm.The task description and command have been properly migrated from Yarn to pnpm, maintaining functional equivalence.
react_on_rails_pro/spec/execjs-compatible-dummy/package.json (2)
2-2: LGTM! Package manager field correctly updated.The packageManager field has been properly set to [email protected], consistent with the monorepo-wide migration.
42-43: LGTM! Scripts correctly migrated to pnpm with yalc integration.The preinstall and link-source scripts have been properly updated to use pnpm while maintaining the necessary yalc workflow for this test dummy app. The combination of pnpm for package management and yalc for local linking is appropriate for this integration test scenario.
packages/react-on-rails/package.json (1)
8-16: LGTM! Scripts correctly migrated to pnpm.All script entries have been properly updated to use pnpm commands. The changes maintain functional equivalence while migrating to the new package manager.
Note: The AI summary mentions a
packageManagerfield update to [email protected], but it's not visible in the provided diff. Ensure this field has been added to maintain consistency with other package.json files in the workspace..npmrc (1)
1-9: LGTM! pnpm configuration appropriately balances compatibility and strictness.The hoisting configuration is well-documented and necessary for compatibility with existing tooling (yalc, Jest). While
shamefully-hoist=trueis less strict than pnpm's default isolated node_modules, it's a pragmatic choice for this migration to maintain compatibility with the existing ecosystem.package.json (1)
69-82: LGTM! Root workspace scripts correctly migrated to pnpm.All script commands have been properly updated to use pnpm with appropriate flags:
-rfor recursive workspace operations--filterfor targeting specific packages- Maintained the postinstall hook for lefthook setup
The migration maintains functional equivalence while leveraging pnpm's workspace features.
CLAUDE.md (3)
74-96: LGTM! Essential commands comprehensively updated to pnpm.All development commands have been properly migrated from Yarn to pnpm, maintaining consistency throughout the documentation. The explicit guidance on line 96 to "Never run npm commands, only equivalent pnpm ones" correctly establishes pnpm as the standard package manager.
Note: The retrieved learning stating "Never use npm commands; only use equivalent Yarn Classic commands for package management" is now outdated by this migration and should be updated to reflect pnpm as the standard.
Based on learnings: The historical learning about Yarn Classic is superseded by this PR's migration to pnpm.
308-339: LGTM! Merge conflict resolution workflow updated for pnpm.The critical workflow section has been updated with pnpm commands, including verification steps for affected scripts. The testing guidance correctly references
pnpm run prepackandpnpm run yalc.publish.
502-541: LGTM! Playwright and general tooling commands migrated to pnpm.All Playwright E2E testing commands and general development tooling references have been consistently updated to use pnpm, including:
- Playwright installation:
pnpm playwright install --with-deps- Test execution:
pnpm test:e2evariants- Clear statement that pnpm is the only supported JS package manager
.claude/docs/testing-build-scripts.md (3)
45-68: LGTM! Testing instructions correctly updated for pnpm.The mandatory testing steps have been properly migrated to pnpm commands, including:
- Clean install testing with
pnpm install --frozen-lockfile- Build and package-specific script testing with pnpm
- Clear emphasis on CI-equivalent testing procedures
112-159: LGTM! Excellent documentation of pnpm workspace dependencies.The new section comprehensively explains:
- Correct workspace:* syntax for pnpm
- Why the previous "*" syntax (Yarn Classic) won't work
- Testing procedures for workspace changes
- Clear comparison with Yarn Classic behavior
This will prevent common migration issues and clarify the workspace protocol differences between package managers.
161-182: LGTM! Historical context aids understanding.The real-world examples document lessons learned from the migration, providing valuable context for:
- Path reference issues during restructuring
- Workspace protocol migration gotchas
- The importance of testing with
pnpm install --frozen-lockfilepackages/react-on-rails-pro/package.json (2)
7-17: LGTM! Scripts correctly migrated to pnpm.All script commands have been properly updated to use pnpm, maintaining functional equivalence with the previous Yarn-based commands.
58-58: LGTM! Workspace dependency correctly usesworkspace:*protocol.The migration from
"*"to"workspace:*"is the correct pattern for pnpm workspaces. This ensures pnpm properly resolves to the local workspace package rather than attempting to fetch from the registry.packages/react-on-rails-pro-node-renderer/package.json (4)
50-50: LGTM: Correct workspace protocol usage.The migration from
"*"to"workspace:*"properly leverages pnpm's native workspace linking, eliminating the need for manual yalc workflow for this internal dependency.
73-81: Scripts correctly migrated to pnpm.The build and type-check scripts properly use pnpm commands. Direct
tscinvocations work since TypeScript is a local devDependency, though usingpnpm exec tscwould make the dependency resolution more explicit.
82-83: Verify yalc workflow compatibility with pnpm.These yalc scripts are retained as part of the migration. Ensure the yalc publish/add workflow still functions correctly under pnpm, as noted in your test plan.
126-126: LGTM: Package manager correctly specified.The
packageManagerfield ensures Corepack uses pnpm 9.14.2, maintaining consistency across all environments.pnpm-workspace.yaml (1)
1-2: LGTM: Minimal workspace configuration is correct.The workspace pattern
packages/*appropriately includes all publishable packages. The spec/dummy test fixture is intentionally excluded from the workspace as it's a development/testing app, not a publishable package.rakelib/lint.rake (2)
20-20: LGTM: Lint commands migrated to pnpm.The eslint task correctly uses pnpm commands, maintaining the same version check and lint functionality.
30-32: LGTM: Autofix and stylelint tasks properly migrated.All linting and formatting commands correctly use pnpm equivalents, preserving the original functionality.
Also applies to: 40-40
rakelib/node_package.rake (1)
10-10: LGTM: Build task migrated to pnpm.The command correctly uses
pnpm yalc:publishto match the script name in package.json (line 82 of react-on-rails-pro-node-renderer/package.json)..github/workflows/lint-js-and-ruby.yml (3)
101-114: LGTM: pnpm setup and caching correctly configured.The workflow uses the official
pnpm/action-setup@v4action with proper store path detection and cache configuration keyed topnpm-lock.yaml. This follows pnpm's recommended GitHub Actions integration pattern.
131-132: LGTM: Dependency installation migrated to pnpm.All installation steps correctly use
pnpm install --frozen-lockfile(equivalent to yarn's--frozen-lockfile) andpnpm add -gfor global packages.Also applies to: 138-138
165-182: LGTM: Build and lint commands properly migrated.All build, lint, type-check, and packaging commands correctly use pnpm equivalents while maintaining the same functionality.
rakelib/dummy_apps.rake (2)
8-12: LGTM: Dummy app installation migrated to pnpm.The task correctly uses
pnpm installand maintains the yalc linking for local development. The yalc workflow will be validated as part of the test plan.
14-14: LGTM: Task dependency correctly updated.The dependency change from
:yarn_installto:pnpm_installmaintains the same task flow with the new package manager..github/workflows/playwright.yml (4)
56-71: LGTM: pnpm setup matches lint workflow pattern.The pnpm configuration follows the same proven pattern used in the lint workflow, with proper caching and store path detection.
74-84: LGTM: Dependencies installed with pnpm.All installation steps correctly use pnpm commands, including the global yalc installation and both root and dummy app dependencies.
87-87: LGTM: Correct use of pnpm exec for Playwright.Using
pnpm exec playwrightensures the command runs with the correct dependency resolution from the pnpm workspace.
97-101: LGTM: Test commands migrated to pnpm.Build and test execution commands properly use
pnpm runequivalents.spec/dummy/package.json (3)
70-71: LGTM: Installation scripts migrated to pnpm.The preinstall and link-source scripts correctly use pnpm commands. The yalc integration is intentionally retained for local development workflow validation.
72-86: LGTM: All test and build scripts use pnpm.Comprehensive migration of all scripts to pnpm equivalents, maintaining the same functionality for testing, linting, and building.
90-90: LGTM: Package manager version pinned.Consistent with other package.json files, using [email protected] across the repository.
.github/workflows/integration-tests.yml (2)
122-135: Clean pnpm setup with consistent caching across job duplication.The pnpm/action-setup and store caching blocks are replicated correctly in both jobs. Cache configuration properly references
pnpm-lock.yamland the store path discovery matches pnpm best practices. No issues detected.Also applies to: 211-224
148-151: Frozen-lockfile usage appropriately conditional on dependency levels.Restricting
--frozen-lockfileto latest/primary dependencies (Node 22, latest) while allowing flexibility for minimum dependencies is a sound pattern that balances reproducibility with test coverage. This enables validation of dependency constraints without blocking minimum-version testing.Also applies to: 156-157, 254-257, 262-263
.github/workflows/package-js-tests.yml (1)
101-114: LGTM — Straightforward pnpm migration with correct setup and cache configuration.The workflow properly migrates from Yarn to pnpm with standard setup, caching, and command patterns. Cache keys and store paths are correct.
Also applies to: 125-132
.github/workflows/examples.yml (2)
157-159: Verify thepnpm yalc:publishworkspace script pattern.The use of
pnpm yalc:publish(instead of direct yalc calls like in integration-tests.yml) suggests a workspace-aware script. Confirm that this script is properly defined in package.json and handles all necessary packages. If this needs to run recursively across packages, verify the command is correct or consider usingpnpm -r run yalc:publish.
119-132: LGTM — Consistent pnpm setup and cache configuration.The pnpm migration follows the established pattern across other workflows. Setup, caching, and installation commands are correct.
Also applies to: 152-155
.github/workflows/pro-lint.yml (1)
100-115: LGTM — Clean pnpm workspace migration with idiomatic filtering.The use of
pnpm --filter(line 169) for package-specific builds is idiomatic and correct. All setup, caching, and lint commands are properly converted. The always-frozen-lockfile approach is appropriate for a lint workflow.Also applies to: 147-162, 178-184
react_on_rails_pro/spec/dummy/package.json (1)
98-103: LGTM — Correct packageManager field and script conversions.The packageManager field correctly specifies
[email protected]as required. Script conversions properly chain pnpm operations with yalc setup. Preinstall/postinstall hooks follow pnpm conventions.Also applies to: 128-128
.github/workflows/pro-integration-tests.yml (3)
102-117: LGTM — Consistent pnpm setup across all three jobs.The pnpm setup blocks are properly replicated in each job with correct store path discovery, caching, and installation. Frozen-lockfile usage is consistent and appropriate for integration testing.
Also applies to: 203-218, 405-420
516-516: LGTM — Playwright integration correctly uses pnpm.Commands are syntactically correct for pnpm:
pnpm playwright install --with-depsandpnpm e2e-testproperly invoke Playwright functionality through the package manager.Also applies to: 519-519
351-356: Artifact naming correctly updated for pnpm.Reference to
pnpm-debug.logis correct and will capture debug logs from pnpm operations for troubleshooting on failure..github/workflows/pro-test-package-and-gem.yml (2)
102-117: LGTM — Consistent pnpm setup across Node-dependent jobs.The pnpm setup is properly configured in jobs that require Node. The third job (rspec-gem-specs) correctly omits pnpm setup as it's Ruby-only.
Also applies to: 208-223
249-256: LGTM — Correct use of pnpm workspace filtering for monorepo tests.The
pnpm --filter react-on-rails-pro-node-renderer cicommand (line 256) correctly uses pnpm's idiomatic filtering syntax for running Jest tests in a specific workspace package.
| "packageManager": "[email protected]", | ||
| "pnpm": { | ||
| "overrides": { | ||
| "sentry-testkit>body-parser": "npm:[email protected]", | ||
| "sentry-testkit>express": "npm:[email protected]" | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
Verify pnpm version is current and stable.
The packageManager field declares [email protected], and overrides have been migrated to pnpm's format. Ensure this version is the intended stable release.
🌐 Web query:
What is the latest stable version of pnpm in the 9.x series?
💡 Result:
The latest stable pnpm in the 9.x series is 9.15.9. [1][2]
Sources:
- npm package page for pnpm (v9.15.9). [1]
- pnpm documentation (9.x installation page). [2]
Update pnpm to the latest stable 9.x release.
The latest stable pnpm in the 9.x series is 9.15.9, while package.json specifies 9.14.2. Update the packageManager field to [email protected].
🤖 Prompt for AI Agents
In package.json around lines 101 to 107, the packageManager field pins pnpm to
9.14.2; update it to the latest stable 9.x (9.15.9) by changing the value of
"packageManager" from "[email protected]" to "[email protected]" and keep the existing
pnpm.overrides block unchanged so only the manager version is bumped.
PR Review: Yarn Classic to pnpm MigrationThis is a well-executed migration with excellent workspace configuration and GitHub Actions updates. However, there are several critical issues that will cause CI failures and need to be fixed before merging. 🔴 Critical Issues (Will Break CI)1. package-scripts.yml line 18 - Uses
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (2)
.claude/agents/pr-testing-agent.md (1)
56-667: Add language identifiers to all fenced code blocks.This new file has 20+ markdown linting violations (MD040: missing language specifications on code blocks). Prettier should auto-fix these, but run formatting immediately:
rake autofixExamples of required fixes:
- Line 56:
```→(or blank code block, remove if unnecessary)- Line 70:
```→bash- Line 82:
```→markdown- And 17+ more throughout the file
Per coding guidelines, "ALWAYS let Prettier and RuboCop handle ALL formatting." Run
rake autofixto resolve all markdown linting violations before commit. If violations persist after autofix, manually verify each code block has a language identifier (bash, ruby, javascript, json, markdown, yaml, etc.).react_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb (1)
249-265: Add nil guard tohandle_stream_cache_hitbefore using@async_barrier.The cache hit path bypasses the nil check in
consumer_stream_async. Whencached_stream_react_componentis called outsidestream_view_containing_react_componentsand a cache hit occurs,handle_stream_cache_hitwill crash at line 259 attempting to call.asyncon nil.The cache miss path is protected—it routes through
handle_stream_cache_miss→render_stream_component_with_props→stream_react_component→consumer_stream_async, which has the required nil check (line 304-306). The cache hit path needs the same protection.Recommendation: Add a nil check before line 259:
- Either in
handle_stream_cache_hitmatching the pattern at line 304-306- Or in
fetch_stream_react_componentbefore callinghandle_stream_cache_hit
🧹 Nitpick comments (6)
packages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.ts (1)
142-142: Fix typo in error messages.The error message contains "eneded" which should be "ended".
Apply this diff to fix the typos:
- rejectChunksPromise('Request already eneded'); + rejectChunksPromise('Request already ended');- reject(new Error('Request already eneded')); + reject(new Error('Request already ended'));Also applies to: 162-162
packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.ts (1)
1-49: Well-structured test helper for parallel test isolation.The factory pattern ensures each test gets a unique
serverBundleCachePath, preventing race conditions. A few observations:
Line 25: The type cast
env.RENDERER_LOG_LEVEL as LevelWithSilentis unsafe—if an invalid value is provided, it will pass TypeScript checks but may cause runtime issues. Consider validating the value against allowed pino log levels.Line 17-19: The synchronous cleanup is acceptable for test setup, but consider wrapping in a try-catch to handle edge cases (e.g., permission errors) gracefully.
Consider adding validation for the log level:
+const validLogLevels = ['fatal', 'error', 'warn', 'info', 'debug', 'trace', 'silent'] as const; + +function getLogLevel(): LevelWithSilent { + const level = env.RENDERER_LOG_LEVEL; + if (level && validLogLevels.includes(level as LevelWithSilent)) { + return level as LevelWithSilent; + } + return 'info'; +} + export function createTestConfig(testName: string): { config: Partial<Config>; bundlePath: string } { // ... - logLevel: (env.RENDERER_LOG_LEVEL as LevelWithSilent | undefined) || 'info', + logLevel: getLogLevel(),packages/react-on-rails-pro-node-renderer/tests/vm.test.ts (1)
196-269: Appropriate adaptation for React 19 compatibility.The validation approach shift from exact
data-react-checksumvalues to content presence and length checks is reasonable given React 19's removal of checksums. The comments clearly explain the rationale.However, the validations are quite permissive—checking for
'<'andlength > 100would pass for many malformed outputs. Consider slightly stronger assertions:- // React 19 removed data-react-checksum, verify component rendered successfully - expect(welcomePageRenderingResult as string).toContain('<'); - expect((welcomePageRenderingResult as string).length).toBeGreaterThan(100); + // React 19 removed data-react-checksum, verify component rendered successfully + expect(welcomePageRenderingResult as string).toMatch(/<\w+[^>]*>/); // Contains HTML tag + expect((welcomePageRenderingResult as string).length).toBeGreaterThan(100);This would ensure actual HTML tags are present rather than just the
<character.react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb (2)
11-11: Document why instance variables are necessary here.The RuboCop disable is broad (entire file). Consider adding a comment explaining that instance variables are required to simulate the streaming context that
stream_view_containing_react_componentsnormally provides, and that these are intentionally shared between the around block and test examples.
724-747: Consider extracting the async setup pattern into a test helper.The pattern of wrapping in
Sync, initializing@async_barrierand@main_output_queue, then draining the queue appears multiple times (lines 366-379, 727-744, 785-789). This could be extracted into a reusable test helper method to reduce duplication.Example:
def with_streaming_context(&block) Sync do @async_barrier = Async::Barrier.new @main_output_queue = Async::Queue.new result = block.call @async_barrier.wait @main_output_queue.close # Drain queue while @main_output_queue.dequeue; end result end endreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb (1)
301-341: Consider thread safety forall_chunksarray.The
all_chunksarray (line 311) is accessed from within an async task (line 319) without explicit synchronization. While Ruby's GIL typically protects array operations, this could be fragile if execution moves to a truly parallel context in the future.Consider using
Async::Queuefor collecting chunks instead:def consumer_stream_async(on_complete:) require "async/variable" if @async_barrier.nil? raise ReactOnRails::Error, "You must call stream_view_containing_react_components to render the view containing the react component" end first_chunk_var = Async::Variable.new chunk_queue = Async::Queue.new if on_complete @async_barrier.async do stream = yield is_first = true stream.each_chunk do |chunk| chunk_queue&.enqueue(chunk) # Thread-safe enqueue if is_first first_chunk_var.value = chunk is_first = false else @main_output_queue.enqueue(chunk) end end first_chunk_var.value = nil if is_first if on_complete chunk_queue.close all_chunks = [] while (chunk = chunk_queue.dequeue) all_chunks << chunk end on_complete.call(all_chunks) end end first_chunk_var.wait first_chunk_var.value end
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (25)
.claude/agents/pr-testing-agent.md(1 hunks).claude/agents/pr-testing-guide.md(1 hunks).claude/docs/analysis/CI_FAILURES_2024-11-21.md(1 hunks).claude/docs/analysis/INDEX.md(2 hunks).github/workflows/examples.yml(2 hunks).github/workflows/integration-tests.yml(5 hunks).github/workflows/lint-js-and-ruby.yml(2 hunks).github/workflows/package-js-tests.yml(1 hunks).github/workflows/playwright.yml(2 hunks).github/workflows/pro-integration-tests.yml(13 hunks).github/workflows/pro-lint.yml(4 hunks).github/workflows/pro-test-package-and-gem.yml(5 hunks)CLAUDE.md(9 hunks)packages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.ts(1 hunks)packages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.js(1 hunks)packages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.ts(1 hunks)packages/react-on-rails-pro-node-renderer/tests/serverRenderRSCReactComponent.test.js(1 hunks)packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.js(0 hunks)packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.ts(1 hunks)packages/react-on-rails-pro-node-renderer/tests/vm.test.ts(11 hunks)packages/react-on-rails-pro-node-renderer/tests/worker.test.ts(1 hunks)react_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb(4 hunks)react_on_rails_pro/lib/react_on_rails_pro/concerns/stream.rb(1 hunks)react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb(7 hunks)react_on_rails_pro/spec/react_on_rails_pro/stream_spec.rb(2 hunks)
💤 Files with no reviewable changes (1)
- packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.js
✅ Files skipped from review due to trivial changes (3)
- .claude/docs/analysis/CI_FAILURES_2024-11-21.md
- packages/react-on-rails-pro-node-renderer/tests/worker.test.ts
- packages/react-on-rails-pro-node-renderer/tests/serverRenderRSCReactComponent.test.js
🚧 Files skipped from review as they are similar to previous changes (1)
- .github/workflows/integration-tests.yml
🧰 Additional context used
📓 Path-based instructions (4)
**/*
📄 CodeRabbit inference engine (CLAUDE.md)
ALWAYS ensure files end with a newline character before every commit/push
Files:
packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.tspackages/react-on-rails-pro-node-renderer/tests/vm.test.tspackages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.tsreact_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rbreact_on_rails_pro/spec/react_on_rails_pro/stream_spec.rbpackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.tspackages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.jsCLAUDE.mdreact_on_rails_pro/lib/react_on_rails_pro/concerns/stream.rbreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
**/*.{js,ts,jsx,tsx,json,md,yml,yaml}
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.{js,ts,jsx,tsx,json,md,yml,yaml}: ALWAYS let Prettier and RuboCop handle ALL formatting - never manually format code
Install Prettier with auto-format capability via git hooks for automatic formatting on changed files before each commit
Files:
packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.tspackages/react-on-rails-pro-node-renderer/tests/vm.test.tspackages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.tspackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.tspackages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.jsCLAUDE.md
**/*.{js,ts,jsx,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Install ESLint with auto-fix capability via git hooks for automatic linting on changed files before each commit
Files:
packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.tspackages/react-on-rails-pro-node-renderer/tests/vm.test.tspackages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.tspackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.tspackages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.js
**/*.rb
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.rb: ALWAYS runbundle exec rubocopand fix ALL violations before every commit/push
ALWAYS let RuboCop handle ALL formatting for Ruby files - never manually format code
Install RuboCop with auto-fix capability via git hooks for automatic linting on changed files before each commit
Files:
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rbreact_on_rails_pro/spec/react_on_rails_pro/stream_spec.rbreact_on_rails_pro/lib/react_on_rails_pro/concerns/stream.rbreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
🧠 Learnings (48)
📓 Common learnings
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to package-scripts.yml : After resolving merge conflicts affecting `package-scripts.yml`, verify no hardcoded paths need updating and test with `yarn run prepack`
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to package-scripts.yml : After resolving merge conflicts affecting `package-scripts.yml`, verify no hardcoded paths need updating and test with `yarn run prepack`
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.yml.claude/agents/pr-testing-agent.md.github/workflows/examples.ymlpackages/react-on-rails-pro-node-renderer/tests/vm.test.tspackages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.ts.claude/agents/pr-testing-guide.mdpackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.ts.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/package-js-tests.yml.github/workflows/pro-integration-tests.yml.github/workflows/playwright.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*webpack* : After resolving merge conflicts affecting webpack configs, verify hardcoded paths and test affected scripts
Applied to files:
.github/workflows/lint-js-and-ruby.ymlpackages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.ts.github/workflows/pro-test-package-and-gem.ymlpackages/react-on-rails-pro-node-renderer/tests/vm.test.tspackages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.tspackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.tsCLAUDE.md.github/workflows/pro-integration-tests.yml.github/workflows/playwright.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to package.json : After resolving merge conflicts affecting `package.json`, verify no hardcoded paths need updating
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/examples.yml.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/package-js-tests.yml.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Run `yarn playwright install --with-deps` in spec/dummy to install Playwright browsers before running E2E tests
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.yml.github/workflows/examples.yml.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml.github/workflows/playwright.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Use `bin/ci-switch-config` to switch between CI configurations (Latest: Ruby 3.4, Node 22, Shakapacker 9.3.0, React 19 vs Minimum: Ruby 3.2, Node 20, Shakapacker 8.2.0, React 18)
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.yml.github/workflows/examples.yml.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to react_on_rails_pro/**/*.{js,ts,jsx,tsx,json,md,yml,yaml} : The `react_on_rails_pro/` directory has its own Prettier/ESLint configuration; both root and Pro directories are linted separately by CI
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.yml.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to packages/react-on-rails/src/**/*.{ts,tsx,js,jsx} : TypeScript in `packages/react-on-rails/src/` compiles to JavaScript in `packages/react-on-rails/lib/` during build process
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.yml.github/workflows/examples.ymlpackages/react-on-rails-pro-node-renderer/tests/vm.test.tspackages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.tspackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.ts.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to react_on_rails_pro/sig/**/*.rbs : Validate Pro package RBS signatures with `cd react_on_rails_pro && bundle exec rake rbs:validate`
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.yml.github/workflows/examples.ymlreact_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rbreact_on_rails_pro/spec/react_on_rails_pro/stream_spec.rb.github/workflows/pro-lint.ymlCLAUDE.mdreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Exclude `/coverage`, `/tmp`, `/gen-examples`, `/packages/react-on-rails/lib`, `/node_modules`, `/spec/dummy/node_modules`, `/spec/dummy/tmp`, `/spec/dummy/app/assets/webpack`, `/spec/dummy/log`, `/spec/dummy/e2e/playwright-report`, `/spec/dummy/test-results` directories in IDE configuration to prevent slowdowns
Applied to files:
.github/workflows/lint-js-and-ruby.ymlpackages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.ts.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.rb : ALWAYS run `bundle exec rubocop` and fix ALL violations before every commit/push
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-lint.ymlCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Use `yalc` for local development when testing React on Rails with external applications
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.yml.github/workflows/examples.yml.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml.github/workflows/playwright.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.{js,ts,jsx,tsx,json,md,yml,yaml} : ALWAYS let Prettier and RuboCop handle ALL formatting - never manually format code
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-lint.ymlCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/dummy/e2e/playwright/**/*.spec.js : Write Playwright E2E tests in `spec/dummy/e2e/playwright/e2e/` directory using the `cypress-on-rails` gem helpers for Rails integration
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.ymlpackages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.tsreact_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml.github/workflows/playwright.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/dummy/** : The dummy app in `spec/dummy/` is a full Rails app for integration testing of the React on Rails gem
Applied to files:
.github/workflows/lint-js-and-ruby.yml.github/workflows/pro-test-package-and-gem.ymlreact_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to /CHANGELOG_PRO.md : Update `/CHANGELOG_PRO.md` for Pro-only features, bug fixes, and changes specific to the react_on_rails_pro package
Applied to files:
.github/workflows/pro-test-package-and-gem.ymlpackages/react-on-rails-pro-node-renderer/tests/vm.test.tsreact_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rbreact_on_rails_pro/spec/react_on_rails_pro/stream_spec.rb.github/workflows/pro-lint.ymlCLAUDE.mdreact_on_rails_pro/lib/react_on_rails_pro/concerns/stream.rbreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/dummy/TESTING_LOCALLY.md : Refer to `spec/dummy/TESTING_LOCALLY.md` for local testing tips and known issues when testing the dummy Rails app
Applied to files:
.github/workflows/pro-test-package-and-gem.yml.claude/agents/pr-testing-guide.mdCLAUDE.md.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-01-23T18:20:45.824Z
Learnt from: alexeyr-ci
Repo: shakacode/react_on_rails PR: 1687
File: spec/dummy/package.json:0-0
Timestamp: 2025-01-23T18:20:45.824Z
Learning: When adding or updating dependencies in spec/dummy/package.json, maintain version consistency with other package.json files in the codebase to avoid potential version conflicts.
Applied to files:
.github/workflows/pro-test-package-and-gem.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to spec/dummy/e2e/playwright/app_commands/**/*.rb : Create custom Rails helper commands for Playwright tests in `spec/dummy/e2e/playwright/app_commands/` directory
Applied to files:
.github/workflows/pro-test-package-and-gem.ymlreact_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml.github/workflows/playwright.yml
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Use `yarn test:e2e` to run Playwright tests; Rails server auto-starts on port 5017
Applied to files:
.github/workflows/pro-test-package-and-gem.ymlpackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.ts.github/workflows/pro-lint.ymlCLAUDE.md.github/workflows/pro-integration-tests.yml.github/workflows/playwright.yml
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: Never use `npm` commands; only use equivalent Yarn Classic commands for package management
Applied to files:
.github/workflows/pro-test-package-and-gem.yml.github/workflows/examples.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Document testing activities in commit messages for complex fixes and note in PR descriptions which fixes were tested locally vs. hypothetical
Applied to files:
.claude/agents/pr-testing-agent.md.claude/agents/pr-testing-guide.mdCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: NEVER claim a test is 'fixed' without running it locally first; use 'SHOULD fix' for untested proposed fixes and 'Analysis suggests' for investigation without fixes
Applied to files:
.claude/agents/pr-testing-agent.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Prefer local testing over CI iteration; do not push 'hopeful' fixes and wait for CI feedback
Applied to files:
.claude/agents/pr-testing-agent.mdCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.958Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.958Z
Learning: When resolving merge conflicts, follow exact sequence: resolve conflicts, verify file paths, auto-fix formatting with `rake autofix`, test critical scripts, then continue merge
Applied to files:
.claude/agents/pr-testing-agent.mdCLAUDE.md
📚 Learning: 2024-12-12T13:07:09.929Z
Learnt from: alexeyr-ci
Repo: shakacode/react_on_rails PR: 1644
File: node_package/src/ReactOnRailsRSC.ts:87-87
Timestamp: 2024-12-12T13:07:09.929Z
Learning: When handling errors in 'node_package/src/ReactOnRailsRSC.ts', include the error stack in error messages in development and test environments to aid debugging.
Applied to files:
packages/react-on-rails-pro-node-renderer/tests/vm.test.ts
📚 Learning: 2025-02-13T19:09:15.991Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: node_package/src/RSCWebpackLoader.ts:0-0
Timestamp: 2025-02-13T19:09:15.991Z
Learning: In React Server Components webpack loader, using `new Function('return import("react-server-dom-webpack/node-loader")')()` is necessary as a workaround to bypass TypeScript compilation issues with direct dynamic imports.
Applied to files:
packages/react-on-rails-pro-node-renderer/tests/vm.test.tspackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.tsCLAUDE.md
📚 Learning: 2025-04-26T21:55:55.874Z
Learnt from: alexeyr-ci2
Repo: shakacode/react_on_rails PR: 1732
File: spec/dummy/client/app-react16/startup/ReduxSharedStoreApp.client.jsx:40-44
Timestamp: 2025-04-26T21:55:55.874Z
Learning: In the react_on_rails project, files under `app-react16` directories are copied/moved to corresponding `/app` directories during the conversion process (removing the `-react16` suffix), which affects their relative import paths at runtime.
Applied to files:
packages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.tspackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.tsreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
📚 Learning: 2025-02-12T16:38:06.537Z
Learnt from: Romex91
Repo: shakacode/react_on_rails PR: 1697
File: package-scripts.yml:28-28
Timestamp: 2025-02-12T16:38:06.537Z
Learning: The file `node_package/lib/ReactOnRails.full.js` is autogenerated during the build process and should not be present in the repository.
Applied to files:
packages/react-on-rails-pro-node-renderer/tests/httpRequestUtils.tsCLAUDE.md
📚 Learning: 2024-10-08T20:53:47.076Z
Learnt from: theforestvn88
Repo: shakacode/react_on_rails PR: 1620
File: spec/dummy/client/app/startup/HelloTurboStream.jsx:3-3
Timestamp: 2024-10-08T20:53:47.076Z
Learning: The `RailsContext` import in `spec/dummy/client/app/startup/HelloTurboStream.jsx` is used later in the project, as clarified by the user theforestvn88.
Applied to files:
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rbreact_on_rails_pro/spec/react_on_rails_pro/stream_spec.rb
📚 Learning: 2025-02-18T13:08:01.477Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: lib/react_on_rails/helper.rb:190-197
Timestamp: 2025-02-18T13:08:01.477Z
Learning: RSC support validation in React on Rails Pro is handled through a chain of validations:
1. Pro version check in `run_stream_inside_fiber`
2. RSC support check during pack generation via `ReactOnRailsPro.configuration.enable_rsc_support`
3. RSC support validation during component registration
This makes additional validation in the helper methods unnecessary.
Applied to files:
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rbreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
📚 Learning: 2025-04-09T13:02:16.009Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1696
File: node_package/src/transformRSCNodeStream.ts:3-31
Timestamp: 2025-04-09T13:02:16.009Z
Learning: In the React Server Components (RSC) stream processing implementation, all chunks end with a newline character (`\n`), so the `lastIncompleteChunk` variable is expected to be empty by the time the stream ends, making a flush handler unnecessary in the Transform stream.
Applied to files:
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb
📚 Learning: 2025-04-09T12:56:10.756Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1696
File: node_package/src/RSCPayloadContainer.ts:0-0
Timestamp: 2025-04-09T12:56:10.756Z
Learning: In the react_on_rails codebase, RSC payloads are already stringified using `JSON.stringify()` before being processed by the `escapeScript` function, which handles escaping of special characters. The function only needs to handle specific HTML markers like comments and closing script tags.
Applied to files:
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rbreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
📚 Learning: 2024-10-08T20:53:47.076Z
Learnt from: justin808
Repo: shakacode/react_on_rails PR: 1622
File: spec/dummy/spec/rake/assets_precompile_rake_spec.rb:12-12
Timestamp: 2024-10-08T20:53:47.076Z
Learning: When stubbing environment variables in RSpec tests, use `before` and `after` hooks to ensure that the original values are restored after the tests, preventing any side effects on other tests. Example provided by justin808:
```ruby
describe "My test" do
before do
original_value = ENV["VARIABLE_NAME"]
allow(ENV).to receive(:[]).with("VARIABLE_NAME").and_return("stubbed_value")
end
after do
allow(ENV).to receive(:[]).with("VARIABLE_NAME").and_call_original
ENV["VARIABLE_NAME"] = original_value
end
it "tests something" do
# Your test code here
end
end
```
This practice ensures test isolation and reliability.
Applied to files:
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb
📚 Learning: 2025-02-13T14:29:49.267Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: spec/react_on_rails/utils_spec.rb:218-218
Timestamp: 2025-02-13T14:29:49.267Z
Learning: In RSpec tests, prefer using local variables over constants within test blocks to avoid constant redefinition warnings and maintain better test isolation.
Applied to files:
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb
📚 Learning: 2025-09-16T08:01:11.146Z
Learnt from: justin808
Repo: shakacode/react_on_rails PR: 1770
File: lib/generators/react_on_rails/templates/base/base/app/javascript/src/HelloWorld/ror_components/HelloWorld.client.jsx:2-2
Timestamp: 2025-09-16T08:01:11.146Z
Learning: React on Rails uses webpack CSS Modules configuration with namedExports: true, which requires the import syntax `import * as style from './file.module.css'` rather than the default export pattern. This configuration enables better tree shaking and bundle size optimization for CSS modules.
Applied to files:
packages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.tspackages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.jsreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
📚 Learning: 2025-07-08T05:57:29.630Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1745
File: node_package/src/RSCRequestTracker.ts:8-14
Timestamp: 2025-07-08T05:57:29.630Z
Learning: The global `generateRSCPayload` function in React on Rails Pro (RORP) is provided by the framework during rendering requests, not implemented in application code. The `declare global` statements are used to document the expected interface that RORP will inject at runtime.
Applied to files:
packages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.tsreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to /CHANGELOG_PRO.md : Do NOT add changelog entries for linting, formatting, refactoring, tests, or documentation-only fixes in the Pro changelog
Applied to files:
.github/workflows/pro-lint.yml.github/workflows/pro-integration-tests.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Validate RBS type signatures with `bundle exec rake rbs:validate` before committing type-checked code
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Run `bundle exec rake rbs:steep` to type-check Ruby code with Steep against RBS signatures
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Run `bundle exec rubocop` to fix ALL violations before pushing (mandatory pre-push requirement)
Applied to files:
.github/workflows/pro-lint.ymlCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.{js,ts,jsx,tsx,json,md,yml,yaml} : Install Prettier with auto-format capability via git hooks for automatic formatting on changed files before each commit
Applied to files:
.github/workflows/pro-lint.ymlCLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.{js,ts,jsx,tsx} : Install ESLint with auto-fix capability via git hooks for automatic linting on changed files before each commit
Applied to files:
CLAUDE.md
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to **/*.rb : Install RuboCop with auto-fix capability via git hooks for automatic linting on changed files before each commit
Applied to files:
CLAUDE.md
📚 Learning: 2025-09-15T21:24:48.207Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1781
File: node_package/src/ClientSideRenderer.ts:82-95
Timestamp: 2025-09-15T21:24:48.207Z
Learning: In React on Rails, the force_load feature includes both explicit `data-force-load="true"` usage and the ability to hydrate components during the page loading state (`document.readyState === 'loading'`). Both capabilities require a Pro license, so the condition `!railsContext.rorPro && (isComponentForceLoaded || document.readyState === 'loading')` correctly gates both scenarios.
Applied to files:
react_on_rails_pro/lib/react_on_rails_pro/concerns/stream.rbreact_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
📚 Learning: 2025-11-24T16:54:16.957Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T16:54:16.957Z
Learning: Applies to lib/react_on_rails/**/*.rb : When creating new Ruby files in `lib/react_on_rails/`, add corresponding RBS type signatures and include in Steepfile for type checking
Applied to files:
react_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
📚 Learning: 2025-02-13T16:50:47.848Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: node_package/src/clientStartup.ts:18-21
Timestamp: 2025-02-13T16:50:47.848Z
Learning: In the react_on_rails module, the `reactOnRailsPageUnloaded` function in clientStartup.ts is intentionally kept private as it's only used internally as a callback for `onPageUnloaded`.
Applied to files:
react_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
📚 Learning: 2025-02-18T13:08:01.477Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1644
File: lib/react_on_rails/helper.rb:190-197
Timestamp: 2025-02-18T13:08:01.477Z
Learning: RSC support validation is handled in deeper level calls of the React on Rails Pro codebase, so it doesn't need to be validated again in the `rsc_payload_react_component` helper method.
Applied to files:
react_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb
🧬 Code graph analysis (7)
packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.ts (2)
packages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.js (1)
createTestConfig(7-7)packages/react-on-rails-pro-node-renderer/src/shared/configBuilder.ts (1)
Config(25-89)
packages/react-on-rails-pro-node-renderer/tests/vm.test.ts (2)
packages/react-on-rails-pro-node-renderer/tests/helper.ts (1)
readRenderingRequest(137-145)packages/react-on-rails-pro-node-renderer/src/worker/vm.ts (1)
runInVM(110-179)
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb (3)
react_on_rails_pro/spec/react_on_rails_pro/stream_spec.rb (1)
include(8-35)spec/dummy/spec/helpers/react_on_rails_helper_spec.rb (1)
include(6-9)packages/react-on-rails-pro/tests/AsyncQueue.ts (1)
dequeue(27-54)
react_on_rails_pro/spec/react_on_rails_pro/stream_spec.rb (1)
packages/react-on-rails-pro/tests/AsyncQueue.ts (2)
dequeue(27-54)enqueue(10-20)
packages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.ts (2)
packages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.js (3)
createTestConfig(7-7)app(8-8)app(24-24)packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.ts (1)
createTestConfig(13-49)
packages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.js (1)
packages/react-on-rails-pro-node-renderer/tests/testingNodeRendererConfigs.ts (1)
createTestConfig(13-49)
react_on_rails_pro/lib/react_on_rails_pro/concerns/stream.rb (2)
react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb (2)
render_to_string(17-17)response(18-18)react_on_rails_pro/spec/react_on_rails_pro/stream_spec.rb (1)
render_to_string(18-34)
🪛 LanguageTool
.claude/agents/pr-testing-guide.md
[style] ~32-~32: Try using a synonym here to strengthen your wording.
Context: ...h pr create`) - Responding to PR review comments about testing - CI failures occur and n...
(COMMENT_REMARK)
[grammar] ~494-~494: Ensure spelling is correct
Context: ...tion tests: rake run_rspec:dummy ### Environment Limitations **Mark any testing blocked...
(QB_NEW_EN_ORTHOGRAPHY_ERROR_IDS_1)
🪛 markdownlint-cli2 (0.18.1)
.claude/docs/analysis/INDEX.md
229-229: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
.claude/agents/pr-testing-guide.md
56-56: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
70-70: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
82-82: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
92-92: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
101-101: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
110-110: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
119-119: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
130-130: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
160-160: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
191-191: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
204-204: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
229-229: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
264-264: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
288-288: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
295-295: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
302-302: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
309-309: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
555-555: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
599-599: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
628-628: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
667-667: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (7)
- GitHub Check: examples (3.4, latest)
- GitHub Check: rspec-package-tests (3.4, latest)
- GitHub Check: rspec-package-tests (3.2, minimum)
- GitHub Check: build-dummy-app-webpack-test-bundles
- GitHub Check: build-dummy-app-webpack-test-bundles
- GitHub Check: pro-lint-js-and-ruby
- GitHub Check: claude-review
🔇 Additional comments (25)
.github/workflows/examples.yml (1)
119-157: LGTM! Pnpm migration is correct.The workflow properly:
- Sets up pnpm/action-setup@v4 with store caching
- Uses
pnpm-lock.yamlfor deterministic builds- Installs with
--frozen-lockfile(good for CI reproducibility)- Replaces yarn commands with pnpm equivalents
- Uses workspace script invocation (
pnpm yalc:publish)Ensure
pnpm-lock.yamlexists and is committed to the repository (cache key on line 128 depends on it).CLAUDE.md (2)
58-100: Excellent comprehensive pnpm migration in CLAUDE.md.The updates correctly:
- Replace all yarn/npm commands with pnpm equivalents
- Maintain command syntax and semantics
- Preserve testing guidance while updating tooling references
- Add explicit guidance ("Only use pnpm as the JS package manager")
506-507: Clear policy on package manager enforcement.The explicit guidance to use only pnpm (never npm or yarn) is strong and clear. This prevents users from accidentally running incompatible package manager commands in a pnpm monorepo.
.github/workflows/lint-js-and-ruby.yml (1)
101-180: LGTM! Comprehensive pnpm migration in linting workflow.The workflow correctly:
- Sets up pnpm with action-setup, store path detection, and caching
- Replaces all yarn commands with pnpm equivalents
- Maintains linting tool invocations (eslint, stylelint, rubocop)
- Properly handles monorepo package operations (pnpm pack, attw, publint)
- Includes frozen-lockfile installs for reproducibility
Verify that all pnpm scripts referenced in this workflow (eslint, lint:scss, type-check, attw, publint, knip) are defined in the respective package.json files (root, packages/react-on-rails, spec/dummy).
.github/workflows/playwright.yml (1)
56-99: LGTM! Correct pnpm migration in Playwright workflow.The workflow properly:
- Sets up pnpm caching and store management
- Installs Playwright browsers with system dependencies via
pnpm exec- Uses monorepo install with frozen-lockfile for reproducibility
- Invokes E2E tests through package.json scripts
.github/workflows/pro-lint.yml (1)
100-182: LGTM! Proper pnpm migration including monorepo filtering.The workflow correctly:
- Sets up pnpm with consistent cache strategy
- Handles multiple apps (pro package, dummy, execjs-compatible-dummy)
- Uses
pnpm --filterfor workspace-targeted builds (line 167)- Invokes build scripts via nps through pnpm (lines 176, 179, 182)
- Maintains Pro-specific RBS and linting validation
.github/workflows/package-js-tests.yml (2)
101-112: pnpm setup and caching configuration looks correct.The pnpm action setup, store path detection, and cache configuration using
pnpm-lock.yamlfollow standard pnpm CI patterns. No issues here.
125-126: Verify pnpm conditional flag syntax and note yalc usage.Line 125 uses a bash ternary to conditionally add
--frozen-lockfile. This should expand correctly but ensure it's been tested. Additionally, while the PR objective is to eliminate yalc through native workspace linking, line 126 still installs it globally. Confirm this is intentional for the current migration phase..github/workflows/pro-test-package-and-gem.yml (2)
102-115: Consistent pnpm setup across both job blocks.Both the
build-dummy-app-webpack-test-bundlesandpackage-js-testsjobs have identical, correct pnpm setup patterns with proper store-path caching and frozen-lockfile flags.Also applies to: 206-219
252-252: Verify the filtered package and ci script exist.The command
pnpm --filter react-on-rails-pro-node-renderer ciuses correct pnpm workspace filtering syntax. Ensure that thereact-on-rails-pro-node-rendererpackage exists in the workspace and has aciscript defined in its package.json..github/workflows/pro-integration-tests.yml (3)
102-115: Consistent and correct pnpm setup across all three job blocks.All three integration test jobs maintain identical, properly configured pnpm setup patterns with correct store-path and cache handling. Good consistency across the workflow.
Also applies to: 201-214, 401-414
347-352: Good addition: pnpm debug log capture.Capturing
pnpm-debug.logon workflow failures is helpful for troubleshooting. The pathreact_on_rails_pro/spec/dummy/pnpm-debug.logis correct for logs generated by pnpm in the dummy app directory.
510-510: Verify Playwright and e2e-test script integration with pnpm.The commands
pnpm playwright install --with-depsandpnpm e2e-testreplace yarn equivalents. Confirm that theplaywrightpackage is properly accessible via pnpm and that thee2e-testscript exists in the dummy app's package.json.Also applies to: 513-513
packages/react-on-rails-pro-node-renderer/tests/vm.test.ts (2)
273-314: Assertion counts correctly updated.The assertion counts are accurate:
- Line 196: 5 components × 2 assertions = 10 ✓
- Line 273: 3 components × 2 assertions = 6 ✓
The validation pattern is consistent with the earlier tests.
317-371: Slightly stronger validation in BionicWorkshop tests.These tests use
toContain('<div')instead oftoContain('<'), which is marginally more specific. For consistency across all render tests, consider using the same pattern everywhere.react_on_rails_pro/lib/react_on_rails_pro/concerns/stream.rb (2)
63-82: Sound async streaming architecture with proper cleanup.The barrier-based coordination is well-structured:
writing_taskconsumes chunks concurrently while component tasks produce themensureblock guarantees queue closure and writer completion- Error handling stops the barrier and re-raises appropriately
One observation: After
@async_barrier.stopon line 75, the barrier won't accept new tasks, but already-running tasks continue until completion. This is likely the desired behavior, but consider whether you want@async_barrier.stop(graceful) vs potentially more aggressive cleanup if an error occurs mid-stream.
51-57: Stream closing behavior is properly handled.Verification confirms that error paths correctly close the response stream. The
ApplicationController#rescue_fromhandler (line 45 ofreact_on_rails_pro/spec/dummy/app/controllers/application_controller.rb) writes diagnostic/error details to the stream and then closes it, exactly as the comment describes. The design is intentional and working correctly: the stream is kept open during error handling to allow error details to be sent, and the application layer handles closing it after writing diagnostic information.packages/react-on-rails-pro-node-renderer/tests/htmlStreaming.test.js (1)
3-7: Clean migration to factory-based test configuration.The switch to
createTestConfigaligns with the parallel test isolation strategy. ThebundlePathis correctly ignored since this test file doesn't need it directly—it's used internally within the config'sserverBundleCachePath.react_on_rails_pro/spec/react_on_rails_pro/stream_spec.rb (2)
18-34: Test mock correctly mirrors production async flow.The updated
render_to_stringmock properly simulates the barrier-based streaming:
- Creates async tasks via
@async_barrier.async- Drains component queues into
@main_output_queue- Uses
nilas the termination signal (matchingqueue.closebehavior)This aligns well with the production implementation in
stream.rb.
5-5: Let me examine the full file to verify whether this import is used:Let me check the full file content to understand the context:
Let me view the complete file to verify the context:
#!/bin/bash # View the full stream_spec.rb file cat react_on_rails_pro/spec/react_on_rails_pro/stream_spec.rbpackages/react-on-rails-pro-node-renderer/tests/concurrentHtmlStreaming.test.ts (1)
8-12: LGTM! Test config factory pattern improves test isolation.The migration to
createTestConfigfactory ensures each test gets an isolated bundle path, preventing race conditions during parallel test execution.react_on_rails_pro/spec/dummy/spec/helpers/react_on_rails_pro_helper_spec.rb (2)
366-379: LGTM! Async context setup correctly simulates streaming environment.The
aroundblock properly initializes the async primitives (@async_barrierand@main_output_queue) within aSyncblock, matching the behavior thatstream_view_containing_react_componentswould provide in production.
392-425: Async streaming test correctly validates implementation.Verification confirms the test at lines 392-425 properly validates the async streaming flow:
- First chunk returned synchronously (line 401)
- Barrier wait ensures async task completion (line 404)
- Remaining chunks consumed from queue (lines 409-411)
- Expected chunk count of 2 remaining chunks verified (line 418)
Implementation in
consumer_stream_asynccorrectly aligns with these expectations: first chunk stored in Async::Variable and returned synchronously, while remaining chunks are enqueued to@main_output_queue.react_on_rails_pro/app/helpers/react_on_rails_pro_helper.rb (2)
131-137: LGTM! Clean extraction of streaming callback.The extraction of
on_completeand delegation toconsumer_stream_asyncmaintains the same public API while enabling the new async streaming architecture.
332-332: LGTM! Proper handling of empty stream edge case.Setting
first_chunk_var.value = nilwhen the stream has no chunks prevents thewaitcall from blocking indefinitely.
| ## Contact & Updates | ||
|
|
||
| These documents were generated on: 2025-11-19 | ||
| These documents were generated on: 2025-11-22 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add language identifier or remove blank code block.
Line 229 has a fenced code block without a language specification. Either specify the language (e.g., bash, python) or remove the block.
-```
+```bash🧰 Tools
🪛 markdownlint-cli2 (0.18.1)
229-229: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
🤖 Prompt for AI Agents
In .claude/docs/analysis/INDEX.md around line 229 there is an empty fenced code
block with no language specified; update the block by either adding an
appropriate language identifier (for example ```bash) and placing the intended
content inside, or remove the entire fenced block if no code/content is needed
so the file no longer contains an empty/unnamed code fence.
PR Review: Migration from Yarn Classic to pnpmThank you for this comprehensive migration PR! I've reviewed the changes and have several critical findings that need attention before this can be merged. 🚨 CRITICAL ISSUES1. Incomplete Migration - Package Manager Still Set to YarnThe root "packageManager": "[email protected]+sha512..."According to the PR description, this should be changed to Impact: This contradicts the entire purpose of the migration and will cause confusion for contributors. Files to update:
2. Missing pnpm Configuration FilesThe PR description mentions adding Expected files: # pnpm-workspace.yaml
packages:
- 'packages/*'# .npmrc
shamefully-hoist=true
strict-peer-dependencies=false3. GitHub Actions Still Configured for YarnAll workflow files are still using:
Files needing updates:
Required changes: # Change from:
cache: yarn
cache-dependency-path: '**/yarn.lock'
# To:
cache: pnpm
cache-dependency-path: '**/pnpm-lock.yaml'# Add pnpm setup before node setup:
- uses: pnpm/action-setup@v4
with:
version: 9.14.2# Change all commands:
yarn install --frozen-lockfile → pnpm install --frozen-lockfile
yarn run build → pnpm run build
yarn global add yalc → pnpm add -g yalc4. Rake Tasks Still Using Yarn# react_on_rails/rakelib/node_package.rake:10
sh "yarn run build && yarn yalc publish"This should be: sh "pnpm run build && pnpm yalc publish"Files to update:
5. Missing Workspace Protocol UpdatesThe PR description mentions converting workspace dependencies from Packages to check:
|
355f31d to
491348a
Compare
PR Review: Yarn Classic → pnpm MigrationThank you for this comprehensive migration! This is a significant infrastructure change that will benefit the project. Here's my review: ✅ Strengths
|
491348a to
288bc57
Compare
Code Review: Yarn to pnpm MigrationI've reviewed PR #2121 and the migration looks solid overall. Here's my detailed feedback: ✅ Strengths1. Proper Workspace Configuration
2. Correct Workspace Protocol UsageAll package.json files properly use
This is the correct pnpm workspace syntax (not Yarn's 3. Comprehensive CI Updates
4. Consistent Rake Task UpdatesAll rake files properly updated:
|
288bc57 to
30198d6
Compare
Code Review: Yarn Classic to pnpm MigrationI've conducted a thorough review of PR #2121 migrating from Yarn Classic to pnpm. This is a significant infrastructure change that appears to be well-executed. Here's my analysis: ✅ Strengths1. Comprehensive Migration Approach
2. GitHub Actions Workflows Well-Updated
3. Good Documentation Updates
4. Proper Cleanup
|
30198d6 to
88b8b09
Compare
Code Review: Yarn to pnpm MigrationI've reviewed this PR for the migration from Yarn Classic to pnpm. Overall, this is a well-structured migration with comprehensive updates across the codebase. Here's my detailed feedback: ✅ Strengths1. Comprehensive Workspace Configuration
2. Correct Workspace Protocol Migration
3. Thorough CI/CD Updates
4. Documentation Excellence
5. Rake Task Updates
|
88b8b09 to
89f8e99
Compare
Comprehensive Code Review: Yarn → pnpm Migration🎯 Overall AssessmentThis is a well-executed migration from Yarn Classic to pnpm with comprehensive updates across the monorepo. The changes are methodical and appear complete. However, there is one important concern about scope creep. ✅ Strengths1. Comprehensive Scope
2. Proper pnpm Configuration
3. Good Testing Practices
|
| Category | Rating |
|---|---|
| Code Quality | ⭐⭐⭐⭐ |
| Test Coverage | ⭐⭐⭐ (waiting for CI) |
| Documentation | ⭐⭐⭐⭐ |
| Security | ⭐⭐⭐⭐⭐ |
| Performance | ⭐⭐⭐⭐⭐ |
| Overall | ⭐⭐⭐⭐ |
Great work! Main concern is mixing streaming refactor with package manager migration.
Reviewed per CLAUDE.md: code quality, bugs, performance, security, test coverage
Code Review: Yarn Classic to pnpm MigrationThis is a well-executed package manager migration with excellent attention to detail. Strengths1. Excellent Migration Approach
2. CI Integration Quality
3. Monorepo Configuration
4. Build Script Safety
Critical Concerns1. Bundled Unrelated ChangesThis PR includes 3 unrelated commits in addition to the pnpm migration:
The streaming refactor (#2111) changes react_on_rails_pro/lib/react_on_rails_pro/concerns/stream.rb - this is a complex Pro feature change with behavior modifications. Recommendation: Consider splitting streaming changes into a separate PR OR clearly document why they're bundled. This makes rollback and bisecting easier if issues arise. 2. Missing --ignore-workspace Flag ExplanationIn integration-tests.yml, dummy apps use pnpm install --ignore-workspace. Why is this needed?
3. pnpm/action-setup Version InconsistencySome workflows specify version: 9 explicitly, others rely on packageManager field auto-detection. Recommend standardizing the approach. Testing Verification NeededPer CLAUDE.md, verify these LOCALLY before merging:
Minor Issues
Security ReviewNo security concerns detected:
Performance ConsiderationsExpected benefits:
Monitor CI build times for first 5-10 runs to establish new baseline. Final RecommendationsBefore Merging:
After Merging: SummaryOverall Assessment: Approve with minor recommendations This is a high-quality migration that is technically sound, well-documented, and follows monorepo best practices. Once CI completes successfully and bundled changes are addressed, this is ready to merge. Great work on a complex infrastructure change! |
89f8e99 to
78cc390
Compare
Code Review: Migrate from Yarn Classic to pnpmThis is a comprehensive migration PR that modernizes the package management infrastructure. Overall, the changes are well-structured and follow best practices for pnpm monorepo management. Below is my detailed review: ✅ StrengthsPackage Manager Configuration
GitHub Actions Updates
Documentation
|
Code Review: Yarn Classic → pnpm MigrationOverall AssessmentThis is a well-executed package manager migration from Yarn Classic to pnpm. The changes are comprehensive and follow the project's testing guidelines. The PR properly updates all relevant files, workflows, and documentation. ✅ Strengths1. Comprehensive Migration
2. CI/CD Updates
3. Documentation
4. Cleanup
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we move all linting changes to a separate PR?
Migrate the react-on-rails monorepo from Yarn Classic (v1.22.22) to pnpm for improved monorepo management, faster installs, and native workspace linking that eliminates the need for yalc in internal development. Key changes: - Add pnpm-workspace.yaml and .npmrc for pnpm configuration - Update packageManager field to [email protected] in all package.json files - Convert workspace dependencies from "*" to "workspace:*" protocol - Move pnpm.overrides from workspace package to root - Replace yarn.lock with pnpm-lock.yaml - Update all GitHub Actions workflows with pnpm setup and commands - Update rake tasks to use pnpm commands - Update CONTRIBUTING.md and CLAUDE.md documentation Note for users: End users of react_on_rails can continue using their preferred package manager (npm, yarn, pnpm, or bun). The generators automatically detect your package manager. These changes only affect contributors working on the react_on_rails codebase itself. Closes #2120 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Remove explicit version: 9 parameter from pnpm/action-setup@v4 steps. The action reads the version from packageManager field in package.json, and specifying both causes a conflict error. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
- Fix pnpm filter command syntax (add 'run' for script execution) - Fix test:js script in dummy app to use jest directly - Update knip config: add ignored deps (nps, attw, publint, jest) - Remove non-existent src/index.ts entry from knip config - Clean up stale ignoreDependencies entries per knip hints - Fix prettier-format script to use pnpm exec instead of pnpm run 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
- Restore @babel/runtime and mini-css-extract-plugin to ignoreDependencies - Remove jest from ignoreDependencies (now properly detected) - Ignore disableHttp2 export (test-only utility) - Fix ESLint no-base-to-string error in LazyApolloGraphQL.tsx - Suppress pre-existing typescript-eslint errors in LazyApolloGraphQL.tsx - Fix eslint-lint script to use pnpm exec instead of pnpm run 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Code Review: Yarn to pnpm MigrationThis is a well-executed migration from Yarn Classic to pnpm. The changes are comprehensive and follow best practices. Strengths1. Comprehensive Configuration
2. Correct Workspace Protocol
3. GitHub Actions Updates
4. Rake Task Updates
5. Documentation Updates
6. Pre-commit Hooks
Recommendations1. Test the Build Scripts Locally (Per CLAUDE.md Requirements) 2. Verify CI Passes Before Merge Overall AssessmentThis is a high-quality migration that follows pnpm best practices. The migration is thorough, well-documented, and maintains backward compatibility for end users. Recommendation: APPROVE after CI passes and manual testing of build scripts is confirmed. Security and Performance Notes
Great work on this migration! |
pnpm resolves dependencies differently than Yarn, requiring knip.ts updates: - Add nps, @arethetypeswrong/cli, publint to ignoreDependencies - Remove eslint-import-resolver-alias, eslint-plugin-import (now detected) - Remove src/index.ts entry from pro package (doesn't exist) - Clean up dummy app ignoreDependencies (now properly detected by pnpm) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
PR Review: Migrate from Yarn Classic to pnpmThank you for this comprehensive migration! This is a significant infrastructure change that modernizes the project's package management. Overall, the PR is well-executed with thorough documentation updates. ✅ Strengths1. Comprehensive Scope
2. Correct Workspace Dependency SyntaxThe migration correctly uses 3. Proper pnpm Configuration.npmrc has appropriate settings: node-linker=hoisted, auto-install-peers=true, shamefully-hoist=true. These ensure compatibility with tools like yalc and Jest. 4. CI Workflow Updates Look Good
5. Documentation ExcellenceThe updated documentation in .claude/docs/testing-build-scripts.md provides excellent context about workspace protocols.
|
- Restore @babel/runtime and mini-css-extract-plugin to ignoreDependencies (still needed for webpack build detection) - Add disableHttp2 export to ignore list (test-only utility in worker.ts) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
CONTRIBUTING.md (1)
619-636: Update npm commands to pnpm for consistency.Lines 623-625 show
npm run buildandnpm packin the react_on_rails directory context. Since the repository has migrated to pnpm, these should be updated topnpm run buildandpnpm packfor consistency with the rest of the migration.The
npm installcommand in line 628 is fine since it's in the test app context and npm can install tarballs regardless of the source package manager.Apply this diff:
**Alternative to Yalc: npm pack (More Reliable)** For a more reliable alternative that exactly mimics real package installation: ```bash # In react_on_rails directory -npm run build -npm pack # Creates react-on-rails-15.0.0.tgz +pnpm run build +pnpm pack # Creates react-on-rails-15.0.0.tgz # In test app directory npm install ../path/to/react_on_rails/react-on-rails-15.0.0.tgz</blockquote></details> </blockquote></details>♻️ Duplicate comments (1)
package.json (1)
103-103: Update pnpm to the latest stable 9.x release (9.15.9).Line 103 pins pnpm to 9.14.2, but the latest stable pnpm 9.x release is 9.15.9 as of Nov 25, 2025. This version includes bug fixes and performance improvements. Update the packageManager field to match.
- "packageManager": "[email protected]", + "packageManager": "[email protected]",📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml📒 Files selected for processing (29)
.claude/docs/pr-splitting-strategy.md(0 hunks).claude/docs/testing-build-scripts.md(7 hunks).github/workflows/examples.yml(2 hunks).github/workflows/gem-tests.yml(0 hunks).github/workflows/integration-tests.yml(5 hunks).github/workflows/lint-js-and-ruby.yml(2 hunks).github/workflows/package-js-tests.yml(1 hunks).github/workflows/playwright.yml(2 hunks).github/workflows/pro-integration-tests.yml(13 hunks).github/workflows/pro-lint.yml(4 hunks).github/workflows/pro-test-package-and-gem.yml(5 hunks).npmrc(1 hunks)CHANGELOG.md(1 hunks)CLAUDE.md(8 hunks)CODING_AGENTS.md(0 hunks)CONTRIBUTING.md(16 hunks)TODO.md(0 hunks)bin/lefthook/eslint-lint(2 hunks)bin/lefthook/prettier-format(2 hunks)knip.ts(1 hunks)package.json(2 hunks)packages/react-on-rails-pro-node-renderer/package.json(3 hunks)packages/react-on-rails-pro/package.json(2 hunks)packages/react-on-rails/package.json(1 hunks)pnpm-workspace.yaml(1 hunks)react_on_rails/rakelib/dummy_apps.rake(1 hunks)react_on_rails/rakelib/lint.rake(3 hunks)react_on_rails/rakelib/node_package.rake(1 hunks)react_on_rails/rakelib/run_rspec.rake(1 hunks)💤 Files with no reviewable changes (4)
- .claude/docs/pr-splitting-strategy.md
- TODO.md
- .github/workflows/gem-tests.yml
- CODING_AGENTS.md
🚧 Files skipped from review as they are similar to previous changes (12)
- packages/react-on-rails/package.json
- CLAUDE.md
- react_on_rails/rakelib/dummy_apps.rake
- .github/workflows/lint-js-and-ruby.yml
- .npmrc
- .github/workflows/package-js-tests.yml
- .github/workflows/pro-lint.yml
- .github/workflows/playwright.yml
- pnpm-workspace.yaml
- packages/react-on-rails-pro/package.json
- react_on_rails/rakelib/lint.rake
- CHANGELOG.md
🧰 Additional context used
📓 Path-based instructions (6)
**/*
📄 CodeRabbit inference engine (CLAUDE.md)
**/*: CRITICAL: Ensure all files end with a newline character
When making changes to directory structure or file paths, run comprehensive grep searches to find all affected files before committing:grep -r 'old/path' . --exclude-dir=node_modules --exclude-dir=.gitFiles:
react_on_rails/rakelib/run_rspec.rakebin/lefthook/eslint-lintpackage.jsonknip.tsreact_on_rails/rakelib/node_package.rakebin/lefthook/prettier-formatpackages/react-on-rails-pro-node-renderer/package.jsonCONTRIBUTING.md**/*.{js,jsx,ts,tsx,json,yaml,yml,css,scss}
📄 CodeRabbit inference engine (CLAUDE.md)
NEVER manually format code - let Prettier and RuboCop handle ALL formatting automatically via
rake autofixFiles:
package.jsonknip.tspackages/react-on-rails-pro-node-renderer/package.jsonpackage.json
📄 CodeRabbit inference engine (CLAUDE.md)
Never run
npmcommands - only use equivalent Yarn Classic commandsFiles:
package.json**/*.{js,jsx,ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Run ESLint linting via
yarn run lintorrake lint:eslintbefore committing JavaScript/TypeScript codeFiles:
knip.ts**/*.ts
📄 CodeRabbit inference engine (CLAUDE.md)
Run
yarn run type-checkto validate TypeScript type safety before committingFiles:
knip.ts.github/workflows/*.yml
📄 CodeRabbit inference engine (CLAUDE.md)
When modifying CI workflows, test all changes locally first via manual execution of equivalent commands before pushing - CI iteration is expensive (10-30 min/cycle)
Files:
.github/workflows/pro-integration-tests.yml.github/workflows/examples.yml.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.yml🧠 Learnings (33)
📓 Common learnings
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to package.json : Never run `npm` commands - only use equivalent Yarn Classic commands📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: CRITICAL: For infrastructure/config changes affecting directory structure, build configs, or CI workflows, perform comprehensive local testing before pushing including: grep for affected files, test build pipeline, run relevant specs, and run full lint checkApplied to files:
.claude/docs/testing-build-scripts.mdreact_on_rails/rakelib/run_rspec.rakebin/lefthook/eslint-lint.github/workflows/pro-integration-tests.yml.github/workflows/examples.ymlbin/lefthook/prettier-format.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-01-23T18:20:45.824Z
Learnt from: alexeyr-ci Repo: shakacode/react_on_rails PR: 1687 File: spec/dummy/package.json:0-0 Timestamp: 2025-01-23T18:20:45.824Z Learning: When adding or updating dependencies in spec/dummy/package.json, maintain version consistency with other package.json files in the codebase to avoid potential version conflicts.Applied to files:
.claude/docs/testing-build-scripts.mdpackage.json.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.yml📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to package.json : Never run `npm` commands - only use equivalent Yarn Classic commandsApplied to files:
.claude/docs/testing-build-scripts.mdbin/lefthook/eslint-lintpackage.jsonreact_on_rails/rakelib/node_package.rake.github/workflows/pro-integration-tests.yml.github/workflows/examples.ymlpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Use `yalc` for local development when testing React on Rails with external applications - this allows local package linking without publishing to npmApplied to files:
.claude/docs/testing-build-scripts.mdbin/lefthook/eslint-lintpackage.jsonreact_on_rails/rakelib/node_package.rake.github/workflows/pro-integration-tests.yml.github/workflows/examples.ymlpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to .github/workflows/*.yml : When modifying CI workflows, test all changes locally first via manual execution of equivalent commands before pushing - CI iteration is expensive (10-30 min/cycle)Applied to files:
.claude/docs/testing-build-scripts.md.github/workflows/pro-integration-tests.yml.github/workflows/examples.yml.github/workflows/pro-test-package-and-gem.yml📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to **/*.ts : Run `yarn run type-check` to validate TypeScript type safety before committingApplied to files:
.claude/docs/testing-build-scripts.mdpackage.jsonbin/lefthook/prettier-formatpackages/react-on-rails-pro-node-renderer/package.jsonCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to **/*.{js,jsx,ts,tsx} : Run ESLint linting via `yarn run lint` or `rake lint:eslint` before committing JavaScript/TypeScript codeApplied to files:
.claude/docs/testing-build-scripts.mdreact_on_rails/rakelib/run_rspec.rakebin/lefthook/eslint-lintpackage.json.github/workflows/pro-integration-tests.ymlbin/lefthook/prettier-formatpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to packages/react-on-rails/src/**/*.{ts,tsx} : TypeScript files in the npm package must be compiled to JavaScript in `packages/react-on-rails/lib/` via `yarn run build`Applied to files:
.claude/docs/testing-build-scripts.mdreact_on_rails/rakelib/run_rspec.rakebin/lefthook/eslint-lintpackage.jsonknip.tsreact_on_rails/rakelib/node_package.rake.github/workflows/pro-integration-tests.yml.github/workflows/examples.ymlbin/lefthook/prettier-formatpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to **/* : When making changes to directory structure or file paths, run comprehensive grep searches to find all affected files before committing: `grep -r 'old/path' . --exclude-dir=node_modules --exclude-dir=.git`Applied to files:
.claude/docs/testing-build-scripts.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to **/*.{js,jsx,ts,tsx,json,yaml,yml,css,scss} : NEVER manually format code - let Prettier and RuboCop handle ALL formatting automatically via `rake autofix`Applied to files:
.claude/docs/testing-build-scripts.mdreact_on_rails/rakelib/run_rspec.rakebin/lefthook/eslint-lintpackage.jsonbin/lefthook/prettier-formatpackages/react-on-rails-pro-node-renderer/package.jsonCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Use the 15-Minute Rule: Before pushing ANY commit, ask if spending 15 more minutes testing locally would discover issues before CI does - if YES, spend the 15 minutesApplied to files:
.claude/docs/testing-build-scripts.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to react_on_rails_pro/**/*.{js,jsx,ts,tsx,json,yaml,yml,css,scss} : The react_on_rails_pro directory has its own Prettier and ESLint configuration - CI lints both directories separatelyApplied to files:
.claude/docs/testing-build-scripts.mdreact_on_rails/rakelib/run_rspec.rakebin/lefthook/eslint-lintpackage.jsonknip.tsreact_on_rails/rakelib/node_package.rake.github/workflows/pro-integration-tests.yml.github/workflows/examples.ymlbin/lefthook/prettier-formatpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to spec/react_on_rails/**/*.rb : Ruby unit tests should be located in `spec/react_on_rails/` and tested via `rake run_rspec:gem`Applied to files:
react_on_rails/rakelib/run_rspec.rakebin/lefthook/eslint-lintknip.ts.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to spec/dummy/e2e/playwright/**/*.spec.js : Playwright E2E tests should use the `cypress-on-rails` gem helpers for Rails integration, including `app()`, `appEval()`, and `appFactories()` from `support/on-rails.js`Applied to files:
react_on_rails/rakelib/run_rspec.rake.github/workflows/pro-integration-tests.ymlpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to lib/generators/react_on_rails/**/*.rb : Rails generators run in host app context and should not assume specific project structure (e.g., `app/javascript/` may not exist) - use `Rails.root` for path resolutionApplied to files:
react_on_rails/rakelib/run_rspec.rakereact_on_rails/rakelib/node_package.rakeCONTRIBUTING.md📚 Learning: 2025-04-26T21:55:55.874Z
Learnt from: alexeyr-ci2 Repo: shakacode/react_on_rails PR: 1732 File: spec/dummy/client/app-react16/startup/ReduxSharedStoreApp.client.jsx:40-44 Timestamp: 2025-04-26T21:55:55.874Z Learning: In the react_on_rails project, files under `app-react16` directories are copied/moved to corresponding `/app` directories during the conversion process (removing the `-react16` suffix), which affects their relative import paths at runtime.Applied to files:
react_on_rails/rakelib/run_rspec.rakebin/lefthook/eslint-lintknip.tsreact_on_rails/rakelib/node_package.rakebin/lefthook/prettier-formatpackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to **/*.rb : CRITICAL: Always run `bundle exec rubocop` and fix ALL violations before every commit/pushApplied to files:
react_on_rails/rakelib/run_rspec.rakeCONTRIBUTING.md📚 Learning: 2025-10-23T17:22:01.074Z
Learnt from: AbanoubGhadban Repo: shakacode/react_on_rails PR: 1875 File: lib/react_on_rails/utils.rb:112-124 Timestamp: 2025-10-23T17:22:01.074Z Learning: In React on Rails, when Pro is installed but not licensed, the intended behavior is to raise an error on boot. The `react_on_rails_pro?` method validates licenses and should raise errors early (including during path resolution in methods like `server_bundle?`) to enforce licensing requirements rather than failing later with obscure errors.Applied to files:
bin/lefthook/eslint-lintCONTRIBUTING.md📚 Learning: 2025-02-18T13:08:01.477Z
Learnt from: AbanoubGhadban Repo: shakacode/react_on_rails PR: 1644 File: lib/react_on_rails/helper.rb:190-197 Timestamp: 2025-02-18T13:08:01.477Z Learning: RSC support validation in React on Rails Pro is handled through a chain of validations: 1. Pro version check in `run_stream_inside_fiber` 2. RSC support check during pack generation via `ReactOnRailsPro.configuration.enable_rsc_support` 3. RSC support validation during component registration This makes additional validation in the helper methods unnecessary.Applied to files:
bin/lefthook/eslint-lint📚 Learning: 2025-02-12T16:38:06.537Z
Learnt from: Romex91 Repo: shakacode/react_on_rails PR: 1697 File: package-scripts.yml:28-28 Timestamp: 2025-02-12T16:38:06.537Z Learning: The file `node_package/lib/ReactOnRails.full.js` is autogenerated during the build process and should not be present in the repository.Applied to files:
knip.tsreact_on_rails/rakelib/node_package.rakepackages/react-on-rails-pro-node-renderer/package.json.github/workflows/integration-tests.ymlCONTRIBUTING.md📚 Learning: 2025-09-16T08:01:11.146Z
Learnt from: justin808 Repo: shakacode/react_on_rails PR: 1770 File: lib/generators/react_on_rails/templates/base/base/app/javascript/src/HelloWorld/ror_components/HelloWorld.client.jsx:2-2 Timestamp: 2025-09-16T08:01:11.146Z Learning: React on Rails uses webpack CSS Modules configuration with namedExports: true, which requires the import syntax `import * as style from './file.module.css'` rather than the default export pattern. This configuration enables better tree shaking and bundle size optimization for CSS modules.Applied to files:
knip.tsreact_on_rails/rakelib/node_package.rakepackages/react-on-rails-pro-node-renderer/package.jsonCONTRIBUTING.md📚 Learning: 2025-02-13T19:09:15.991Z
Learnt from: AbanoubGhadban Repo: shakacode/react_on_rails PR: 1644 File: node_package/src/RSCWebpackLoader.ts:0-0 Timestamp: 2025-02-13T19:09:15.991Z Learning: In React Server Components webpack loader, using `new Function('return import("react-server-dom-webpack/node-loader")')()` is necessary as a workaround to bypass TypeScript compilation issues with direct dynamic imports.Applied to files:
knip.ts📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to lib/react_on_rails/**/*.rb : When creating new Ruby files in `lib/react_on_rails/`, create corresponding RBS signature file in `sig/react_on_rails/` and add to Steepfile for type checkingApplied to files:
knip.tsCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: React on Rails is a Rails Engine - automatically loads all `.rake` files from `lib/tasks/` directory without explicit loading via `rake_tasks` block to avoid duplicate task executionApplied to files:
knip.tsreact_on_rails/rakelib/node_package.rakepackages/react-on-rails-pro-node-renderer/package.jsonCONTRIBUTING.md📚 Learning: 2025-02-13T16:50:47.848Z
Learnt from: AbanoubGhadban Repo: shakacode/react_on_rails PR: 1644 File: node_package/src/clientStartup.ts:18-21 Timestamp: 2025-02-13T16:50:47.848Z Learning: In the react_on_rails module, the `reactOnRailsPageUnloaded` function in clientStartup.ts is intentionally kept private as it's only used internally as a callback for `onPageUnloaded`.Applied to files:
knip.ts📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to CHANGELOG_PRO.md : Update CHANGELOG_PRO.md for Pro-only user-visible changes. Use `/update-changelog` command for guided updates with automatic formattingApplied to files:
.github/workflows/pro-integration-tests.ymlbin/lefthook/prettier-formatCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to spec/dummy/**/*.rb : Integration tests in the dummy app should be located in `spec/dummy/` and tested via `rake run_rspec:dummy`Applied to files:
.github/workflows/pro-integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to spec/dummy/.env* : Test database and Redis configuration is managed via environment variables in the dummy app - refer to TESTING_LOCALLY.md for configuration requirementsApplied to files:
.github/workflows/pro-integration-tests.yml.github/workflows/pro-test-package-and-gem.ymlCONTRIBUTING.md📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR Repo: shakacode/react_on_rails PR: 0 File: CLAUDE.md:0-0 Timestamp: 2025-11-25T04:54:35.286Z Learning: Applies to CHANGELOG.md : Update CHANGELOG.md for user-visible changes only (features, bug fixes, breaking changes, deprecations, performance improvements). Do NOT add entries for linting, formatting, refactoring, tests, or documentation fixesApplied to files:
CONTRIBUTING.md📚 Learning: 2025-07-08T05:57:29.630Z
Learnt from: AbanoubGhadban Repo: shakacode/react_on_rails PR: 1745 File: node_package/src/RSCRequestTracker.ts:8-14 Timestamp: 2025-07-08T05:57:29.630Z Learning: The global `generateRSCPayload` function in React on Rails Pro (RORP) is provided by the framework during rendering requests, not implemented in application code. The `declare global` statements are used to document the expected interface that RORP will inject at runtime.Applied to files:
CONTRIBUTING.md📚 Learning: 2025-09-15T21:24:48.207Z
Learnt from: AbanoubGhadban Repo: shakacode/react_on_rails PR: 1781 File: node_package/src/ClientSideRenderer.ts:82-95 Timestamp: 2025-09-15T21:24:48.207Z Learning: In React on Rails, the force_load feature includes both explicit `data-force-load="true"` usage and the ability to hydrate components during the page loading state (`document.readyState === 'loading'`). Both capabilities require a Pro license, so the condition `!railsContext.rorPro && (isComponentForceLoaded || document.readyState === 'loading')` correctly gates both scenarios.Applied to files:
CONTRIBUTING.md📚 Learning: 2024-10-08T20:53:47.076Z
Learnt from: theforestvn88 Repo: shakacode/react_on_rails PR: 1620 File: spec/dummy/client/app/startup/HelloTurboStream.jsx:3-3 Timestamp: 2024-10-08T20:53:47.076Z Learning: The `RailsContext` import in `spec/dummy/client/app/startup/HelloTurboStream.jsx` is used later in the project, as clarified by the user theforestvn88.Applied to files:
CONTRIBUTING.md🪛 LanguageTool
CONTRIBUTING.md
[uncategorized] ~22-~22: “React” is a proper noun and needs to be capitalized.
Context: ...sites Note for users: End users of react_on_rails can continue using their prefe...(A_GOOGLE)
[uncategorized] ~22-~22: “React” is a proper noun and needs to be capitalized.
Context: ...low are for contributors working on the react_on_rails codebase itself. - [Yalc](htt...(A_GOOGLE)
[style] ~311-~311: Three successive sentences begin with the same word. Consider rewording the sentence or use a thesaurus to find a synonym.
Context: ...figs, then you need to restart Foreman. If you change the JS code for react-on-rai...(ENGLISH_WORD_REPEAT_BEGINNING_RULE)
🪛 markdownlint-cli2 (0.18.1)
.claude/docs/testing-build-scripts.md
114-114: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (10)
- GitHub Check: build-dummy-app-webpack-test-bundles (3.2, 20, minimum)
- GitHub Check: rspec-package-tests (3.4, latest)
- GitHub Check: rspec-package-tests (3.2, minimum)
- GitHub Check: examples (3.4, latest)
- GitHub Check: examples (3.2, minimum)
- GitHub Check: build
- GitHub Check: pro-lint-js-and-ruby
- GitHub Check: build-dummy-app-webpack-test-bundles
- GitHub Check: build-dummy-app-webpack-test-bundles
- GitHub Check: claude-review
🔇 Additional comments (31)
react_on_rails/rakelib/run_rspec.rake (1)
113-116: LGTM! Clean migration to pnpm.The task description and command have been correctly updated to use pnpm equivalents.
react_on_rails/rakelib/node_package.rake (1)
8-11: LGTM! Correctly migrated to pnpm with script-based yalc workflow.The change from
yarn yalc publishtopnpm yalc:publishcorrectly uses the workspace script approach, which aligns with the pnpm workspace protocol mentioned in the PR objectives.bin/lefthook/eslint-lint (2)
34-36: LGTM! Correct pnpm command usage.Using
pnpm exec eslintis the proper pnpm equivalent ofyarn run eslintfor executing package binaries.
51-53: LGTM! Consistent migration in Pro directory.The Pro directory ESLint execution correctly uses
pnpm execwithin the subdirectory context.bin/lefthook/prettier-format (2)
26-27: LGTM! Proper pnpm migration.Correctly uses
pnpm exec prettierto execute the Prettier binary.
41-42: LGTM! Consistent Pro directory handling.Maintains the same subdirectory execution pattern with pnpm.
CONTRIBUTING.md (1)
22-23: LGTM! Clear user communication.Good addition clarifying that end users can continue using their preferred package manager while contributors use pnpm.
.github/workflows/examples.yml (2)
119-130: LGTM! Proper pnpm caching setup.The workflow correctly:
- Sets up pnpm using the official action
- Discovers the pnpm store path
- Configures caching with the correct key based on pnpm-lock.yaml
150-157: LGTM! Clean migration to pnpm commands.The installation and publishing steps correctly use pnpm equivalents with appropriate flags (
--frozen-lockfilefor deterministic installs) and the workspace script for yalc publishing.knip.ts (1)
41-45: LGTM! Appropriate Knip configuration updates.The new ignoreDependencies entries are well-documented:
npsis used via package-scripts.yml which Knip doesn't analyze@arethetypeswrong/cliandpublintare package validation tools used in CI/scripts.github/workflows/pro-test-package-and-gem.yml (3)
102-125: LGTM! Complete pnpm setup for Pro dummy app build.The workflow correctly:
- Sets up pnpm
- Configures store path and caching
- Updates system information reporting to include pnpm version
133-140: LGTM! Proper pnpm workspace handling.The installation steps correctly:
- Install global yalc via
pnpm add -g- Use
--frozen-lockfilefor Pro package- Use
--ignore-workspacefor dummy app to prevent workspace collision
246-253: LGTM! Correct use of pnpm workspace filtering.Line 253 properly uses
pnpm --filterto run tests for a specific workspace package, which is the pnpm equivalent of Yarn's workspace commands..claude/docs/testing-build-scripts.md (1)
120-142: Workspace protocol syntax and examples are correct.Lines 125, 132-133, 139-141 correctly document the
workspace:*protocol for pnpm workspace dependencies. This aligns with pnpm's native workspace linking (replacing yalc in the long term).package.json (2)
69-82: Scripts migration to pnpm is complete and correct.All workspace scripts properly use
pnpm -r(recursive) andpnpm --filter(selective) operations. Build script correctly chains multiple filtered builds for the three packages.
104-109: pnpm.overrides configuration is correct.The overrides block properly handles transitive dependency conflicts for sentry-testkit, using pnpm's native override mechanism instead of Yarn's resolutions field.
packages/react-on-rails-pro-node-renderer/package.json (3)
50-50: Workspace dependency protocol correctly migrated.Line 50 properly uses
"workspace:*"for local workspace dependency onreact-on-rails, enabling pnpm's native linking without yalc.
73-81: Scripts correctly migrated from Yarn to pnpm.Lines 73-81 properly replace Yarn commands with pnpm equivalents. Line 79 correctly omits redundant
yarn runprefix since tsc is directly invoked.
126-126: The stated rationale for this version update is unsupported.The review comment claims the update is "for consistency across the monorepo," but no other
packageManagerdeclarations exist in the codebase—only this single file specifies a pnpm version. Additionally, pnpm v9.15.9 is not the latest stable; newer 10.x and 11.x releases exist, so recommending the 9.x line may not reflect the current state of available versions.The update from 9.14.2 to 9.15.9 itself is a reasonable patch bump, but the justification provided does not align with the actual monorepo structure or the broader pnpm release landscape.
Likely an incorrect or invalid review comment.
.github/workflows/integration-tests.yml (5)
122-133: pnpm cache setup is properly configured.Lines 122-133 correctly implement pnpm setup with pnpm/action-setup@v4, store path discovery, and cache configuration using pnpm-lock.yaml as the cache key.
146-157: pnpm install commands are correctly configured.Lines 148-149 properly handle dependency level (frozen vs non-frozen lock), and lines 154-157 correctly use
--ignore-workspacefor the dummy app, preventing it from being treated as part of the parent workspace.
211-222: Second pnpm setup block is consistent with first job.Lines 211-222 properly duplicate pnpm setup in the rspec job, maintaining consistency across jobs with same cache configuration and store path setup.
252-267: Dummy app rspec job install commands mirror build job correctly.Lines 252-267 maintain consistency with the build job's pnpm install strategy, including dependency level handling and workspace isolation for the dummy app.
328-329: Artifact naming correctly updated to pnpm.Lines 328-329 properly update artifact name and path to reference pnpm-debug.log, aligning with pnpm's debug logging convention.
.github/workflows/pro-integration-tests.yml (7)
102-115: pnpm cache setup matches standard configuration across workflows.Lines 102-115 correctly implement pnpm setup with proper cache configuration using pnpm-lock.yaml, consistent with integration-tests.yml workflow.
133-141: Pro package install commands are correctly configured.Lines 133-141 properly handle pnpm installation for the Pro package and dummy app, with helpful comments explaining the
--ignore-workspaceflag to prevent treating the dummy app as part of the parent workspace.
203-216: Second pnpm setup in rspec job maintains consistency.Lines 203-216 properly duplicate pnpm setup for the rspec job with identical cache configuration, maintaining consistency across all Pro integration test jobs.
263-271: rspec job install commands maintain consistency with build job.Lines 263-271 mirror the install strategy from the build job, with proper handling of yalc setup and workspace isolation for the Pro dummy app.
351-356: pnpm debug log artifact naming is updated correctly.Lines 351-356 properly update artifact naming and path to reference pnpm-debug.log, consistent with other workflows.
465-473: e2e job pnpm setup and install commands are correct.Lines 465-473 (along with their corresponding setup blocks at lines 405-418) properly configure pnpm for the Playwright E2E test job, including yalc setup and workspace isolation.
516-519: Playwright installation uses correct pnpm commands.Lines 516 and 519 correctly use
pnpm playwright install --with-depsfor Playwright setup andpnpm e2e-testfor test execution, following pnpm workspace conventions.
| ## Workspace Dependencies: PNPM | ||
|
|
||
| **CRITICAL: This project uses Yarn Classic (v1.x), not Yarn Berry (v2+)** | ||
| **CRITICAL: This project uses PNPM (v9+)** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix markdown formatting: convert emphasis to proper heading.
Line 114 uses emphasis (**Workspace Dependencies: PNPM**) where a proper Markdown heading (##) is more semantically correct and improves document navigation.
Apply this diff:
-## Workspace Dependencies: PNPM
+## Workspace Dependencies: PNPMPer markdownlint (MD036), prefer heading syntax over emphasis formatting for section headers.
Committable suggestion skipped: line range outside the PR's diff.
🧰 Tools
🪛 markdownlint-cli2 (0.18.1)
114-114: Emphasis used instead of a heading
(MD036, no-emphasis-as-heading)
🤖 Prompt for AI Agents
In .claude/docs/testing-build-scripts.md around line 114, the section header is
formatted with emphasis (**Workspace Dependencies: PNPM**) instead of a Markdown
heading; replace the emphasized text with an appropriate heading (e.g., prepend
"## " or other heading level) so the line becomes a proper Markdown header and
adheres to markdownlint rule MD036.
- Add src/worker.ts to entry points so disableHttp2 export is recognized - Remove @babel/runtime and mini-css-extract-plugin from ignoreDependencies (now properly detected by knip with pnpm) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
…cies These dependencies are used by webpack but not detected by knip's analysis. Adding them to ignoreDependencies prevents the "Unused dependencies" error. (This will generate configuration hints, but hints don't fail CI.) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
The pnpm migration changed yarn to pnpm but missed that eslint is invoked via nps, not directly as a package.json script. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Code Review: Yarn Classic to pnpm MigrationSummaryThis is a solid, well-executed migration from Yarn Classic to pnpm. The PR demonstrates thorough attention to detail and follows best practices for monorepo package manager migrations. Overall: ✅ Ready to merge with minor suggestions below. ✅ Strengths1. Correct Workspace Protocol Usage
2. Comprehensive CI/CD Updates
3. Proper pnpm Configuration
4. Rake Task Updates
5. Documentation
🔍 Observations & Minor Suggestions1. Package Scripts - Prepare HookBoth "prepare": "[ -f lib/ReactOnRails.full.js ] || (rm -rf ./lib && tsc)"Observation: This conditional check is good for avoiding unnecessary rebuilds during development. However:
2. Dummy App Package Scripts
"preinstall": "pnpm run link-source && yalc add --link react-on-rails",
"link-source": "cd ../../.. && pnpm run build && cd packages/react-on-rails && yalc publish"Observation: The preinstall hook calls Recommendation: Consider documenting the proper setup order in CONTRIBUTING.md:
However, since this is existing behavior (was the same with yarn), no changes needed for this PR. ✅ 3. Pro Dummy App Complexity
"preinstall": "pnpm run link-source && yalc add --link react-on-rails-pro && cd .yalc/react-on-rails-pro && yalc add --link react-on-rails && cd ../.. && yalc add --link react-on-rails-pro-node-renderer",
"link-source": "cd ../../.. && pnpm install && pnpm run yalc:publish && cd react_on_rails_pro && pnpm install && yalc publish"Observation: This is complex and fragile. The preinstall hook runs However: This is pre-existing complexity from the Yarn setup, not introduced by this PR. The migration maintains existing behavior. ✅ Future improvement (not for this PR): Consider simplifying the dev setup workflow or documenting it more clearly. 4. Missing
|
pnpm uses scripts differently than yarn - when a script calls a binary from node_modules/.bin, it needs to just reference the binary name directly. Added missing scripts that master has: - nps, knip, eslint, attw, publint Also simplified lint command to just use 'nps eslint' directly. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
PR Review: Migrate from Yarn Classic to pnpm✅ Overall AssessmentThis is a well-executed infrastructure migration from Yarn Classic to pnpm. The PR is comprehensive, well-documented, and follows best practices for package manager migrations in monorepos. 🎯 Strengths1. Complete Migration Coverage
2. Proper pnpm Configuration
3. CI/CD Best Practices
4. Documentation Updates
5. Workspace Dependency Management
|
Prettier was trying to parse .npmrc as YAML and failing because it's actually INI format. Add it to .prettierignore to skip formatting checks. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Auto-formatted markdown files that prettier was complaining about. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
7c0c090 to
10cafc1
Compare
PR Review: Migrate from Yarn Classic to pnpmThank you for this comprehensive migration! Overall this is a well-executed migration with excellent attention to detail. ✅ Strengths1. Correct pnpm Configuration
2. Comprehensive Workflow Updates
3. Rake Tasks and Scripts
4. Documentation
🔍 Key ObservationsWorkspace Dependencies - Excellent! npmrc Configuration - Well Chosen Lock File Size - Expected
|
The stylelint path should use react_on_rails/spec/dummy/ not spec/dummy/ after the monorepo restructure. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Comprehensive Code Review - PR #2121: Yarn to pnpm MigrationThank you for this thorough migration! I've reviewed the changes comprehensively. Overall, this is a well-executed migration with one critical blocking issue that needs to be addressed before merging. ✅ What's Done Well1. Package Configuration (Excellent)
2. GitHub Actions (Complete)
3. Lock Files (Clean)
4. Documentation (Thorough)
🚨 CRITICAL ISSUE - BLOCKINGPro Package Rake Tasks Not MigratedThe Pro package's rake tasks still reference File: task :eslint do
sh_in_dir(gem_root, "yarn run eslint") # ❌ Should be pnpm
endFile: task :yarn_install do
yarn_install_cmd = "yarn install --frozen-lockfile --mutex network" # ❌ Should be pnpm
sh_in_dir(dummy_app_dir, yarn_install_cmd)
endImpact:
Required Fix: # lint.rake line 22
task :eslint do
sh_in_dir(gem_root, "pnpm run eslint")
end
# dummy_apps.rake lines 10-12
task :pnpm_install do
pnpm_install_cmd = "pnpm install --frozen-lockfile"
sh_in_dir(dummy_app_dir, pnpm_install_cmd)
endAnd update task dependencies from
|
| Category | Status | Notes |
|---|---|---|
| Package.json configuration | ✅ Complete | Workspace protocol correct |
| pnpm config files | ✅ Complete | Appropriate for tooling compatibility |
| GitHub Actions | ✅ Complete | All workflows updated |
| Rake tasks (open source) | ✅ Complete | Updated to pnpm |
| Rake tasks (Pro) | ❌ INCOMPLETE | BLOCKING ISSUE |
| Lock files | ✅ Complete | Clean migration |
| Documentation | ✅ Complete | Thorough updates |
✅ Approval Conditions
Before merging, please:
- Fix Pro package rake tasks (critical)
- Test locally:
pnpm install --frozen-lockfilepnpm run buildcd react_on_rails_pro && bundle exec rake lint:eslint
- Wait for CI to pass (currently in progress)
Once the Pro package rake tasks are fixed and CI passes, this will be ready to merge. The migration is otherwise very well done! 🎉
📚 Code Quality Notes
Best Practices Followed
✅ Consistent naming throughout
✅ Proper git history preservation for lock file changes
✅ No breaking changes for end users (only affects contributors)
✅ Clear communication in PR description
Adherence to CLAUDE.md
✅ Follows "Testing Build Scripts" requirements
✅ Documentation properly updated
bundle exec rubocop before final commit (per CLAUDE.md critical requirements)
Great work on this migration! Just need to complete the Pro package updates.
Use String(updateError) instead of updateError.toString() to satisfy the @typescript-eslint/no-base-to-string rule. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
String() still triggers the rule since it calls toString() internally. Use JSON.stringify() instead which properly handles object types. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
pnpm's strict dependency resolution doesn't hoist the root's newer Babel version like Yarn did. Update the dummy app's Babel versions to be compatible with @babel/plugin-syntax-import-attributes. Also includes the JSON.stringify fix for ESLint. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Wrap the long line for proper formatting per Prettier rules. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Code Review: Yarn to pnpm MigrationThis is a well-executed migration from Yarn Classic to pnpm. The changes are comprehensive and follow best practices. Strengths1. Correct Workspace Configuration
2. Package Manager Field
3. Comprehensive CI Updates
4. Script Migrations
5. Documentation
6. Dependency Management
Potential Issues1. CRITICAL: Test Local Build Scripts ManuallyAccording to CLAUDE.md guidelines, you MUST test these commands manually before merging. The PR description shows CI workflows and yalc publish workflow are NOT yet tested. This is risky since build scripts are infrastructure code that can silently fail. 2. Missing packageManager FieldThe packageManager field is missing in packages/react-on-rails/package.json and packages/react-on-rails-pro/package.json. Recommendation: Add packageManager [email protected] to ensure consistency. 3. Dummy Apps Non-Deterministic InstallsDummy apps intentionally do not have pnpm-lock.yaml files. This is correct per CI setup but could lead to flaky tests if transitive dependencies update. Overall AssessmentThis is a high-quality migration that is comprehensive, properly documented, and follows pnpm best practices. Risk Level: Medium - The migration itself is solid. Main risk is untested yalc workflow and CI. Once CI passes, this should be safe to merge. Action Items Before Merge
Great work on this migration! The attention to detail is impressive. |
The Check TypeScript step needs working-directory: . to run from the root where check-typescript nps script is defined. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Code Review: Yarn Classic → pnpm MigrationOverviewThis is a comprehensive migration from Yarn Classic to pnpm for the react-on-rails monorepo. The changes are well-structured and follow pnpm best practices. Overall, this is a solid migration with proper configuration and thorough updates across the codebase. ✅ Strengths1. Proper pnpm Configuration
2. Correct Workspace ProtocolAll workspace dependencies correctly use workspace:* syntax (proper pnpm workspace syntax vs. Yarn Classic's "*"). 3. Comprehensive CI Updates
4. Build Scripts and Rake Tasks
5. Documentation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
react_on_rails/spec/dummy/package.json (1)
24-24: <!-- [scratchpad_start]
[task review_file_1/1 verify_yalc_migration_1/2]
Analyzing script output to confirm original review's accuracy about yalc references.[observations]
- Script output shows extensive yalc usage throughout repo (170+ matches)
- Specific to react_on_rails/spec/dummy/package.json (the file under review):
- Line 24: "react-on-rails": "link:.yalc/react-on-rails" ✓ CONFIRMED
- Line 70: "preinstall": includes "yalc add --link react-on-rails" ✓ CONFIRMED
- Line 71: "link-source": includes "yalc publish" ✓ CONFIRMED
- Also shows yalc in react_on_rails_pro/spec/dummy/package.json and react_on_rails_pro/spec/execjs-compatible-dummy/package.json
- Root package.json still has "yalc:publish" and "yalc" scripts
[analysis]
The original review comment is ACCURATE about the specific file. However, output indicates:
- This appears to be incomplete migration - yalc is still referenced throughout codebase
- Similar issues likely exist in react_on_rails_pro package.json files (not just react_on_rails/spec/dummy)
- PR objective states migration should remove yalc, but actual code contradicts this
- Must verify: Is this PR intended to migrate ALL dummy apps or just react_on_rails/spec/dummy?
[pending]
- Check if PR scope includes react_on_rails_pro files or just react_on_rails/spec/dummy
- Verify whether other dummy app package.json files were also meant to be updated in same PR
- Confirm the exact PR objectives and scope
[actions]
- Query package.json file to see actual current state with line numbers
- Check git diff or PR description to understand scope
- Verify if react_on_rails_pro files are included in this PR
[scratchpad_end]
--><!-- [scratchpad_start]
[task review_file_1/1 verify_workspace_protocol_1/1]
Confirmed pnpm workspace protocol syntax and behavior.[observations]
- Web search confirms: workspace:* is the standard syntax for pnpm workspace references
- Original review comment correctly identifies that line 24 should use "workspace:*" instead of "link:.yalc/react-on-rails"
- pnpm workspace protocol automatically handles linking during development
- Yalc is not needed with pnpm workspaces for internal monorepo packages
[analysis]
The review comment's core claim is technically sound. With pnpm workspaces:
- Dependencies on workspace packages should use workspace:* protocol
- This replaces the need for yalc add/publish commands
- The preinstall script with yalc operations becomes unnecessary
- Scripts can be simplified
[observations_continued]
From script output: yalc is still referenced in:
- react_on_rails/spec/dummy/package.json (the file under review)
- react_on_rails_pro/spec/dummy/package.json
- react_on_rails_pro/spec/execjs-compatible-dummy/package.json
- Root package.json and multiple other files
[pending]
- Need to check PR scope: Does this PR update ALL dummy apps or only react_on_rails/spec/dummy?
- Need to verify: Are react_on_rails_pro files also part of this PR or separate?
[done]
- Verified pnpm workspace:* protocol is correct and standard
- Confirmed yalc references contradict PR objectives
- Original review comment is technically accurate
[scratchpad_end]
-->Now let me check the actual scope of this PR to determine if other files should also have been updated:<!-- [scratchpad_start]
[task review_file_1/1 verify_pr_scope_final_1/1]
Web search didn't provide specific PR details but confirmed standard pnpm practices.[observations]
- Web search shows pnpm workspace:* protocol is standard practice across monorepos
- No specific react_on_rails PR details found in web search
- The code review shows only react_on_rails/spec/dummy/package.json in the current snippet
- Script output revealed other similar files: react_on_rails_pro/spec/dummy/package.json, react_on_rails_pro/spec/execjs-compatible-dummy/package.json that also still reference yalc
- Cannot determine from web search alone if PR scope includes react_on_rails_pro files
[analysis]
CRITICAL FINDINGS:
- The review comment identifies three critical yalc references in react_on_rails/spec/dummy/package.json (lines 24, 70, 71)
- The original review comment is technically accurate and the issues exist
- The PR objective (stated in the comment) clearly says "replace yalc with pnpm workspace:*"
- The fact that yalc is still present in the file contradicts this objective
- Similar issues exist in other dummy app package.json files (react_on_rails_pro), suggesting this may be incomplete migration
KEY QUESTION STILL PENDING:
- Is this PR intended to update ONLY react_on_rails/spec/dummy or also react_on_rails_pro files?
- Cannot determine from available information if react_on_rails_pro files should have been updated in the SAME PR
[recommendation]
The original review comment is fundamentally CORRECT in identifying the yalc references in react_on_rails/spec/dummy/package.json as issues that contradict the stated PR objective. However, I should verify whether the review comment scope is complete or if it's missing mention of react_on_rails_pro files.Since the script output shows other files with same issues, I should check if this was intentional (separate PR) or an oversight. However, the current review is scoped to ONE file, so the core issues identified are valid.
[done]
- Confirmed original review is technically accurate
- Confirmed pnpm workspace:* is correct protocol
- Confirmed yalc references contradict stated PR objective
- Verified issue exists in the file under review
- Unable to determine broader PR scope details
[scratchpad_end]
-->Critical: Remove yalc references incompatible with pnpm workspace migration.
According to the PR objectives, the migration should "replace manual yalc publish/add with pnpm workspace:* native linking" and remove yalc entirely. However, this file still contains yalc references in three locations that contradict this goal:
- Line 24: Dependency points to
.yalc/react-on-railsinstead of using theworkspace:*protocol- Line 70:
preinstallscript callsyalc add --link react-on-rails- Line 71:
link-sourcescript callsyalc publishWith pnpm workspaces, dependencies on workspace packages should use the
workspace:*protocol, which instructs pnpm to look for the package within your workspace folders before checking external registries. These yalc operations are redundant and should be removed.Fix these issues:
- Set Line 24 to
"react-on-rails": "workspace:*"- Remove or simplify yalc commands from lines 70–71 (the preinstall script can be removed entirely if pnpm's automatic workspace resolution is sufficient)
Also note: Similar yalc references remain in other package.json files (react_on_rails_pro/spec/dummy, etc.), suggesting a broader pattern across the codebase that may need attention.
🧹 Nitpick comments (2)
react_on_rails_pro/spec/dummy/client/app/components/LazyApolloGraphQL.tsx (1)
80-82: Unrelated change: error display method update.This error display change appears unrelated to the pnpm migration stated in the PR objectives. While
JSON.stringify()may be an improvement overtoString(), GraphQL/Apollo errors often have structured properties that stringify poorly.Optional: improve error display clarity.
Consider displaying specific error properties for better readability:
- {updateError && ( - <div style={{ color: 'red' }}>Error while updating User: {JSON.stringify(updateError)}</div> - )} + {updateError && ( + <div style={{ color: 'red' }}> + Error while updating User: {updateError.message || JSON.stringify(updateError)} + </div> + )}.github/workflows/pro-lint.yml (1)
99-186: Assess CI test readiness against coding guidelines.Per your coding guidelines, CI workflows should be tested locally first via manual execution of equivalent commands before pushing, as "CI iteration is expensive (10-30 min/cycle)." The PR objectives state: "CI workflows and yalc publish/add workflow remain pending."
This indicates that these workflow changes have not yet passed CI validation. Before merging, ensure:
- All pnpm commands in this workflow have been executed locally and produce expected output (build succeeds, linting passes, format/TypeScript checks pass).
- The full CI job has been run (or simulated locally) to catch environment-specific issues (cache behavior, path resolution, permissions, Node/pnpm version compatibility).
- The cache strategy (pnpm store path + lock file hash) has been validated to avoid cache misses or stale installs on subsequent runs.
Once these tests pass locally, the workflow is ready for CI integration.
Would you like me to generate a script that simulates the key steps of this workflow (setup Node, pnpm, cache, install, build, lint) so you can validate the changes locally before pushing to CI?
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (4)
.github/workflows/pro-lint.yml(4 hunks)package-scripts.yml(1 hunks)react_on_rails/spec/dummy/package.json(3 hunks)react_on_rails_pro/spec/dummy/client/app/components/LazyApolloGraphQL.tsx(1 hunks)
🧰 Additional context used
📓 Path-based instructions (5)
**/*
📄 CodeRabbit inference engine (CLAUDE.md)
**/*: CRITICAL: Ensure all files end with a newline character
When making changes to directory structure or file paths, run comprehensive grep searches to find all affected files before committing:grep -r 'old/path' . --exclude-dir=node_modules --exclude-dir=.git
Files:
package-scripts.ymlreact_on_rails_pro/spec/dummy/client/app/components/LazyApolloGraphQL.tsxreact_on_rails/spec/dummy/package.json
**/*.{js,jsx,ts,tsx,json,yaml,yml,css,scss}
📄 CodeRabbit inference engine (CLAUDE.md)
NEVER manually format code - let Prettier and RuboCop handle ALL formatting automatically via
rake autofix
Files:
package-scripts.ymlreact_on_rails_pro/spec/dummy/client/app/components/LazyApolloGraphQL.tsxreact_on_rails/spec/dummy/package.json
.github/workflows/*.yml
📄 CodeRabbit inference engine (CLAUDE.md)
When modifying CI workflows, test all changes locally first via manual execution of equivalent commands before pushing - CI iteration is expensive (10-30 min/cycle)
Files:
.github/workflows/pro-lint.yml
**/*.{js,jsx,ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Run ESLint linting via
yarn run lintorrake lint:eslintbefore committing JavaScript/TypeScript code
Files:
react_on_rails_pro/spec/dummy/client/app/components/LazyApolloGraphQL.tsx
react_on_rails_pro/**/*.{js,jsx,ts,tsx,json,yaml,yml,css,scss}
📄 CodeRabbit inference engine (CLAUDE.md)
The react_on_rails_pro directory has its own Prettier and ESLint configuration - CI lints both directories separately
Files:
react_on_rails_pro/spec/dummy/client/app/components/LazyApolloGraphQL.tsx
🧠 Learnings (20)
📓 Common learnings
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to package.json : Never run `npm` commands - only use equivalent Yarn Classic commands
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to packages/react-on-rails/src/**/*.{ts,tsx} : TypeScript files in the npm package must be compiled to JavaScript in `packages/react-on-rails/lib/` via `yarn run build`
Applied to files:
package-scripts.yml.github/workflows/pro-lint.ymlreact_on_rails/spec/dummy/package.json
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to **/*.ts : Run `yarn run type-check` to validate TypeScript type safety before committing
Applied to files:
package-scripts.yml.github/workflows/pro-lint.yml
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to react_on_rails_pro/**/*.{js,jsx,ts,tsx,json,yaml,yml,css,scss} : The react_on_rails_pro directory has its own Prettier and ESLint configuration - CI lints both directories separately
Applied to files:
package-scripts.yml.github/workflows/pro-lint.ymlreact_on_rails/spec/dummy/package.json
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to **/*.{js,jsx,ts,tsx} : Run ESLint linting via `yarn run lint` or `rake lint:eslint` before committing JavaScript/TypeScript code
Applied to files:
package-scripts.yml.github/workflows/pro-lint.ymlreact_on_rails/spec/dummy/package.json
📚 Learning: 2025-04-26T21:55:55.874Z
Learnt from: alexeyr-ci2
Repo: shakacode/react_on_rails PR: 1732
File: spec/dummy/client/app-react16/startup/ReduxSharedStoreApp.client.jsx:40-44
Timestamp: 2025-04-26T21:55:55.874Z
Learning: In the react_on_rails project, files under `app-react16` directories are copied/moved to corresponding `/app` directories during the conversion process (removing the `-react16` suffix), which affects their relative import paths at runtime.
Applied to files:
package-scripts.ymlreact_on_rails/spec/dummy/package.json
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to **/*.{js,jsx,ts,tsx,json,yaml,yml,css,scss} : NEVER manually format code - let Prettier and RuboCop handle ALL formatting automatically via `rake autofix`
Applied to files:
package-scripts.yml.github/workflows/pro-lint.yml
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: CRITICAL: For infrastructure/config changes affecting directory structure, build configs, or CI workflows, perform comprehensive local testing before pushing including: grep for affected files, test build pipeline, run relevant specs, and run full lint check
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to package.json : Never run `npm` commands - only use equivalent Yarn Classic commands
Applied to files:
.github/workflows/pro-lint.ymlreact_on_rails/spec/dummy/package.json
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: This is a monorepo with two separate changelogs: `/CHANGELOG.md` for open source and `/CHANGELOG_PRO.md` for Pro features - update the appropriate changelog(s) based on change scope
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Use `yalc` for local development when testing React on Rails with external applications - this allows local package linking without publishing to npm
Applied to files:
.github/workflows/pro-lint.ymlreact_on_rails/spec/dummy/package.json
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to spec/dummy/e2e/playwright/**/*.spec.js : Playwright E2E tests should use the `cypress-on-rails` gem helpers for Rails integration, including `app()`, `appEval()`, and `appFactories()` from `support/on-rails.js`
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to spec/react_on_rails/**/*.rb : Ruby unit tests should be located in `spec/react_on_rails/` and tested via `rake run_rspec:gem`
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-10-23T17:22:01.074Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1875
File: lib/react_on_rails/utils.rb:112-124
Timestamp: 2025-10-23T17:22:01.074Z
Learning: In React on Rails, when Pro is installed but not licensed, the intended behavior is to raise an error on boot. The `react_on_rails_pro?` method validates licenses and should raise errors early (including during path resolution in methods like `server_bundle?`) to enforce licensing requirements rather than failing later with obscure errors.
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2025-01-23T18:20:45.824Z
Learnt from: alexeyr-ci
Repo: shakacode/react_on_rails PR: 1687
File: spec/dummy/package.json:0-0
Timestamp: 2025-01-23T18:20:45.824Z
Learning: When adding or updating dependencies in spec/dummy/package.json, maintain version consistency with other package.json files in the codebase to avoid potential version conflicts.
Applied to files:
.github/workflows/pro-lint.ymlreact_on_rails/spec/dummy/package.json
📚 Learning: 2025-11-25T04:54:35.286Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T04:54:35.286Z
Learning: Applies to **/*.rb : CRITICAL: Always run `bundle exec rubocop` and fix ALL violations before every commit/push
Applied to files:
.github/workflows/pro-lint.yml
📚 Learning: 2024-12-12T13:07:09.929Z
Learnt from: alexeyr-ci
Repo: shakacode/react_on_rails PR: 1644
File: node_package/src/ReactOnRailsRSC.ts:87-87
Timestamp: 2024-12-12T13:07:09.929Z
Learning: When handling errors in 'node_package/src/ReactOnRailsRSC.ts', include the error stack in error messages in development and test environments to aid debugging.
Applied to files:
react_on_rails_pro/spec/dummy/client/app/components/LazyApolloGraphQL.tsx
📚 Learning: 2025-06-09T07:58:02.646Z
Learnt from: AbanoubGhadban
Repo: shakacode/react_on_rails PR: 1696
File: node_package/src/RSCPayloadGenerator.ts:124-168
Timestamp: 2025-06-09T07:58:02.646Z
Learning: In React Server Components (RSC) implementations, explicit error handling in RSC payload generation streams (like in RSCPayloadGenerator.ts) is not needed because errors will propagate to client components that fetch the RSC payloads (such as RSCRoute components). React's built-in error handling mechanisms and ErrorBoundary components are sufficient for handling these errors at the component level, which allows for better user experience with appropriate error UI fallbacks.
Applied to files:
react_on_rails_pro/spec/dummy/client/app/components/LazyApolloGraphQL.tsx
📚 Learning: 2025-02-12T16:38:06.537Z
Learnt from: Romex91
Repo: shakacode/react_on_rails PR: 1697
File: package-scripts.yml:28-28
Timestamp: 2025-02-12T16:38:06.537Z
Learning: The file `node_package/lib/ReactOnRails.full.js` is autogenerated during the build process and should not be present in the repository.
Applied to files:
react_on_rails/spec/dummy/package.json
📚 Learning: 2025-09-16T08:01:11.146Z
Learnt from: justin808
Repo: shakacode/react_on_rails PR: 1770
File: lib/generators/react_on_rails/templates/base/base/app/javascript/src/HelloWorld/ror_components/HelloWorld.client.jsx:2-2
Timestamp: 2025-09-16T08:01:11.146Z
Learning: React on Rails uses webpack CSS Modules configuration with namedExports: true, which requires the import syntax `import * as style from './file.module.css'` rather than the default export pattern. This configuration enables better tree shaking and bundle size optimization for CSS modules.
Applied to files:
react_on_rails/spec/dummy/package.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (10)
- GitHub Check: examples (3.4, latest)
- GitHub Check: examples (3.2, minimum)
- GitHub Check: rspec-package-tests (3.2, minimum)
- GitHub Check: rspec-package-tests (3.4, latest)
- GitHub Check: build-dummy-app-webpack-test-bundles (3.2, 20, minimum)
- GitHub Check: build-dummy-app-webpack-test-bundles
- GitHub Check: build
- GitHub Check: build-dummy-app-webpack-test-bundles
- GitHub Check: pro-lint-js-and-ruby
- GitHub Check: claude-review
🔇 Additional comments (6)
package-scripts.yml (2)
18-18: Pnpm --filter syntax is correct.The change from
yarn workspace <name> run <cmd>topnpm --filter <name> run <cmd>correctly implements the pnpm equivalent for workspace targeting. The pattern is applied consistently across all three workspace packages.
1-65: Ensure file ends with a newline and formatting is applied.Per coding guidelines, all files must end with a newline character, and YAML files should have formatting applied via
rake autofixrather than manually.Please confirm:
- The file ends with a newline character after line 65
- Formatting has been applied via
rake autofixprior to commitreact_on_rails/spec/dummy/package.json (2)
73-73: Verify format script invocation.Line 73 calls
pnpm run nps format, which mixes thenpstool with pnpm. Verify that the rootpackage.jsonhas annpsscript configured, or if this should be simplified topnpm run formatdirectly.
90-90: Verify packageManager specification.The
packageManagerfield is correctly updated to[email protected], which aligns with the PR objectives..github/workflows/pro-lint.yml (2)
156-162: Approve pnpm installation strategy for dummy applications.The use of
--ignore-workspaceflag for Pro dummy app and ExecJS dummy app installations is correct; this prevents pnpm from treating these apps as part of the parent monorepo workspace and ensures their dependencies are isolated and properly installed from their respective lock files.
100-113: pnpm cache strategy is correctly configured for this monorepo structure.Verification confirms:
- Root
pnpm-lock.yamlexists and is the single source of truth for lock versioningpnpm-workspace.yamldefines the monorepo structure correctly- The glob pattern
**/pnpm-lock.yamlappropriately matches the root lock file without false positives- The
pnpm store path --silentcommand and cache strategy follow pnpm's standard best practicesNo issues detected in the pnpm setup, store detection, or caching approach for lines 100–113.
| - name: Install Node modules with pnpm for Pro package | ||
| run: | | ||
| sudo yarn global add yalc | ||
| yarn install --frozen-lockfile --no-progress --no-emoji | ||
| pnpm add -g yalc | ||
| pnpm install --frozen-lockfile |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
Verify necessity of global yalc installation in this workflow.
Line 147 installs yalc globally via pnpm add -g yalc, but this workflow (pro-lint.yml) does not appear to invoke yalc in subsequent steps. According to the PR objectives, yalc usage is transitional and the long-term goal is to replace it with pnpm workspace linking.
Confirm whether this line is:
- Needed by a later step in this workflow (not visible in the provided code), or
- Intended for downstream workflows/jobs (publish/add), or
- A leftover from Yarn migration that should be removed.
If yalc is not used in this specific workflow, consider removing it to reduce installation time and simplify the Pro package setup.
🏁 Script executed:
#!/bin/bash
# Description: Search for yalc usage patterns in the pro-lint workflow and related files
# Check if yalc is referenced anywhere in pro-lint.yml after installation
echo "=== Searching for yalc references in pro-lint.yml ==="
grep -n "yalc" .github/workflows/pro-lint.yml
# Check for yalc usage in Pro package scripts
echo "=== Checking react_on_rails_pro package.json for yalc references ==="
grep -i "yalc" react_on_rails_pro/package.json || echo "No yalc references found"
# Check other workflows that might depend on yalc being pre-installed
echo "=== Searching for yalc in other CI workflows ==="
grep -r "yalc" .github/workflows/ --include="*.yml" | grep -v pro-lint.yml | head -10Length of output: 1082
Remove unused yalc global installation from pro-lint.yml.
The pnpm add -g yalc command at line 147 is not used anywhere in this workflow. Other workflows (examples.yml, integration-tests.yml) install yalc because they actually invoke it in subsequent steps, but pro-lint.yml does not. Removing this line reduces unnecessary installation overhead.
- name: Install Node modules with pnpm for Pro package
run: pnpm install --frozen-lockfile
🤖 Prompt for AI Agents
In .github/workflows/pro-lint.yml around lines 145 to 148, the workflow installs
yalc globally with `pnpm add -g yalc` even though this workflow never uses yalc;
remove that line so the step simply runs `pnpm install --frozen-lockfile` (i.e.,
replace the multi-line run block with a single line running pnpm install
--frozen-lockfile) to avoid unnecessary global installation and speed up the
job.
| - name: Build react-on-rails package (required for Pro eslint import resolution) | ||
| working-directory: . | ||
| run: yarn workspace react-on-rails-pro build | ||
| run: pnpm --filter react-on-rails-pro build |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
Verify pnpm command syntax and cross-check with package.json scripts.
The migration from Yarn to pnpm commands appears syntactically correct:
pnpm --filter react-on-rails-pro build(line 169): Uses correct --filter syntax for targeted builds.pnpm run nps eslint(line 178),pnpm run nps format.listDifferent(line 181),pnpm run nps check-typescript(line 185): Use correct pnpm run syntax.
However, confirm that:
- The
nps(npm-run-all) scripts are defined in the root or Pro package package.json and that pnpm can correctly resolve and invoke them. - The build target in line 169 matches the actual package name in pnpm-workspace.yaml (verify "react-on-rails-pro" is the correct --filter name).
- These commands produce identical output and behavior to their Yarn equivalents (especially the nps invocations, which may have subtle differences in environment/path handling).
Also applies to: 178-178, 181-181, 185-185
🏁 Script executed:
#!/bin/bash
# Description: Verify pnpm command syntax and script availability
# Verify react-on-rails-pro is a valid workspace in pnpm-workspace.yaml
echo "=== Checking pnpm workspace configuration ==="
cat pnpm-workspace.yaml
# Verify nps scripts exist in root package.json
echo "=== Checking for nps scripts in root package.json ==="
grep -A 5 '"scripts"' package.json | grep -E "(eslint|format|check-typescript)" || echo "No direct nps script references found"
# Verify react-on-rails-pro build script exists
echo "=== Checking Pro package build script ==="
jq '.scripts.build' react_on_rails_pro/package.json 2>/dev/null || grep '"build"' react_on_rails_pro/package.json
# Test that pnpm can resolve the --filter target
echo "=== Verifying pnpm recognizes react-on-rails-pro workspace ==="
grep -i "react-on-rails-pro" pnpm-workspace.yaml || grep -i "react-on-rails-pro" package.jsonLength of output: 518
I need to gather more information about the package.json files and script definitions to fully verify the pnpm migration.
Need to investigate further into the actual package.json files and script definitions.
I need to verify the actual package.json files and build script definitions more thoroughly.
🏁 Script executed:
#!/bin/bash
# Inspect full package.json files to understand scripts and build configuration
echo "=== Full react_on_rails_pro/package.json ==="
cat react_on_rails_pro/package.json 2>/dev/null || echo "File not found"
echo ""
echo "=== Root package.json - full scripts section ==="
jq '.scripts' package.json 2>/dev/null | head -40 || echo "jq failed, trying grep..."
echo ""
echo "=== Checking for nps/npm-run-all in dependencies ==="
grep -i "nps\|npm-run-all" package.json react_on_rails_pro/package.json 2>/dev/null || echo "Not found in either file"
echo ""
echo "=== Checking if package-scripts.js or nps config exists ==="
find . -maxdepth 2 -name "package-scripts.js" -o -name ".npsrc*" 2>/dev/null || echo "Not found"Length of output: 1682
Let me search for nps task definitions in other possible locations:
🏁 Script executed:
#!/bin/bash
# Search for nps configuration in various locations
echo "=== Searching for nps task definitions ==="
find . -maxdepth 3 -type f \( -name "*.js" -o -name "*.yml" -o -name "*.yaml" -o -name "*.json" \) -exec grep -l "eslint\|format\.listDifferent\|check-typescript" {} \; 2>/dev/null | grep -v node_modules | head -20
echo ""
echo "=== Checking .npsrc.json or similar ==="
ls -la .* 2>/dev/null | grep -i nps || echo "No nps-related hidden files"
echo ""
echo "=== Checking if nps scripts are embedded in package.json ==="
grep -A 50 '"nps"' package.json | grep -E "(eslint|format|typescript)" || echo "Not found in root package.json nps section"
echo ""
echo "=== Checking git status for recent changes to workflow ==="
git log --oneline .github/workflows/pro-lint.yml 2>/dev/null | head -5 || echo "Cannot access git history"Length of output: 940
Now I need to check the package-scripts.yml files to see if the nps tasks are properly defined:
🏁 Script executed:
#!/bin/bash
# Check nps task definitions in package-scripts.yml files
echo "=== Root package-scripts.yml ==="
cat package-scripts.yml 2>/dev/null | head -100
echo ""
echo "=== react_on_rails_pro/package-scripts.yml ==="
cat react_on_rails_pro/package-scripts.yml 2>/dev/null | head -100
echo ""
echo "=== Verify if tasks exist for: eslint, format.listDifferent, check-typescript ==="
grep -E "(eslint|format\.listDifferent|check-typescript)" package-scripts.yml react_on_rails_pro/package-scripts.yml 2>/dev/nullLength of output: 9160
Fix workflow commands to properly invoke nps tasks for react-on-rails-pro builds.
Line 169 calls pnpm --filter react-on-rails-pro build, but react_on_rails_pro/package.json has no build script. The build task is defined only in react_on_rails_pro/package-scripts.yml. Change to pnpm --filter react-on-rails-pro run nps build to properly invoke the nps task.
Lines 178, 181, and 185 are correct and will work as-is (nps tasks are properly defined in root package-scripts.yml).
Note: The root package.json's build script (line containing pnpm --filter react-on-rails-pro run build) has the same issue and should also be changed to pnpm --filter react-on-rails-pro run nps build.
🤖 Prompt for AI Agents
In .github/workflows/pro-lint.yml around line 169 the workflow invokes "pnpm
--filter react-on-rails-pro build" but react_on_rails_pro defines its build via
nps (package-scripts.yml) not an npm "build" script; replace that invocation
with "pnpm --filter react-on-rails-pro run nps build" so the nps task is
executed. Also update the root package.json build script (the line that
currently runs "pnpm --filter react-on-rails-pro run build") to call "pnpm
--filter react-on-rails-pro run nps build" for the same reason; leave the other
workflow lines (178, 181, 185) unchanged.
| "private": true, | ||
| "dependencies": { | ||
| "@babel/runtime": "7.17.9", | ||
| "@babel/runtime": "^7.22.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
Verify Babel version consistency across monorepo.
Lines 10 and 32 update @babel/runtime and @babel/core to ^7.22.0. Ensure these versions are consistent with Babel versions specified in other package.json files in the monorepo to avoid version conflicts.
Also applies to: 32-32
🏁 Script executed:
#!/bin/bash
# Check all package.json files for Babel version consistency
echo "=== @babel/runtime versions ==="
rg '"@babel/runtime"' package.json
echo ""
echo "=== @babel/core versions ==="
rg '"@babel/core"' package.jsonLength of output: 92
I need to run a corrected search to properly find all Babel versions across the monorepo. The first script used incorrect syntax that didn't search recursively.
🏁 Script executed:
#!/bin/bash
# Find all package.json files and extract Babel versions
echo "=== All package.json files ==="
fd package.json
echo ""
echo "=== @babel/runtime versions across all package.json files ==="
fd package.json --exec rg -H '"@babel/runtime"' {}
echo ""
echo "=== @babel/core versions across all package.json files ==="
fd package.json --exec rg -H '"@babel/core"' {}
echo ""
echo "=== Checking spec/dummy/package.json specifically ==="
cat spec/dummy/package.json | grep -A1 -B1 '@babel'Length of output: 2062
Let me check the root package.json to understand the monorepo structure better:
🏁 Script executed:
#!/bin/bash
# Check root package.json for workspaces and Babel packages
echo "=== Root package.json (first 50 lines) ==="
head -50 package.json
echo ""
echo "=== Root package.json Babel/dependencies section ==="
cat package.json | grep -A20 '"dependencies"' | head -30
echo ""
echo "=== Check if react_on_rails/spec/dummy/package.json has both packages at line 10 and 32 ==="
sed -n '8,34p' react_on_rails/spec/dummy/package.jsonLength of output: 2655
Address Babel version inconsistency across monorepo package.json files.
Verification confirms the concern is valid. @babel/runtime and @babel/core versions are not consistent:
- Root workspace (
package.json):@babel/core:^7.20.12(no@babel/runtime) - react_on_rails/spec/dummy (being updated):
@babel/runtime:^7.22.0,@babel/core:^7.22.0 - Other packages:
react_on_rails_prouses7;pro-node-rendereruses^7.26.10
Either update the root package.json to match ^7.22.0 (and add @babel/runtime), or align react_on_rails/spec/dummy with root versions to maintain consistency and avoid workspace version conflicts.
🤖 Prompt for AI Agents
In react_on_rails/spec/dummy/package.json around line 10, the @babel
runtime/core versions conflict with the monorepo root and other packages; update
the root package.json to add "@babel/runtime": "^7.22.0" and bump "@babel/core"
to "^7.22.0" (or alternatively change react_on_rails/spec/dummy to match the
root) so all workspace package.json files use the same @babel core/runtime
versions to avoid version conflicts.
Update NPM publish commands in release.rake to use pnpm: - Use `pnpm publish` from package directories instead of yarn workspace - Remove --new-version flag (pnpm uses version from package.json) - Replace --no-git-tag-version with --no-git-checks for node-renderer 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
|
Thanks for the thorough review! 🔴 CRITICAL: Release Tasks - FIXED ✅Fixed in commit a0f62cd. Updated
Key changes:
🟡 Dummy App Workspace IsolationYes,
This matches local development behavior when testing with the dummy apps. 🟡 Missing Lock Files for Dummy AppsThe dummy apps share the root lockfile via workspace configuration. They don't have independent locks because:
🟢 Pro Package OverridesGood suggestion. The overrides exist because All items addressed. Ready for re-review! |
Summary
Migrate the react-on-rails monorepo from Yarn Classic (v1.22.22) to pnpm for improved monorepo management, faster installs, and native workspace linking.
Key Changes
Package Manager Configuration
pnpm-workspace.yamland.npmrcfor pnpm configurationpackageManagerfield to[email protected]in all package.json files"*"to"workspace:*"protocolpnpm.overridesfrom workspace package to rootLock Files
yarn.lockfilespnpm-lock.yamlGitHub Actions Workflows
yarn.locktopnpm-lock.yamlRake Tasks
rakelib/lint.rake,rakelib/node_package.rake,rakelib/dummy_apps.rake,rakelib/run_rspec.rakeDocumentation
CONTRIBUTING.mdandCLAUDE.mdNote for Users
End users of react_on_rails can continue using their preferred package manager (npm, yarn, pnpm, or bun). The generators automatically detect your package manager. These changes only affect contributors working on the react_on_rails codebase itself.
Test Plan
pnpm installcompletes successfullypnpm run buildproduces correct artifactsCloses #2120
🤖 Generated with Claude Code
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.