Skip to content

Conversation

@justin808
Copy link
Member

@justin808 justin808 commented Nov 26, 2025

Summary

  • Adds comprehensive documentation for upgrading from React on Rails v16.0.x to v16.1.1
  • Creates new release notes file at docs/upgrading/release-notes/16.1.0.md
  • Updates main upgrade guide with quick reference section

Changes

New: docs/upgrading/release-notes/16.1.0.md

Complete upgrade guide covering:

  • Step-by-step upgrade instructions
  • New features documentation:
    • rake react_on_rails:doctor diagnostic command
    • Server bundle security options (server_bundle_output_path, enforce_private_server_bundles)
    • Generator improvements with modern TypeScript patterns
  • Deprecation notices (e.g., generated_assets_dirs)
  • Bug fixes in v16.1.0 and v16.1.1
  • Security enhancements
  • Version compatibility matrix
  • Common troubleshooting issues

Updated: docs/upgrading/upgrading-react-on-rails.md

  • Added quick upgrade summary for v16.1.x section
  • Links to detailed release notes

Closes #1831

Test plan

  • Verify markdown renders correctly on GitHub
  • Verify internal links work
  • Review technical accuracy of upgrade steps

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Documentation
    • Added detailed v16.1.x release notes and upgrade guide with step-by-step upgrade workflow, version alignment instructions, installation commands, troubleshooting tips, and noted bug fixes.
    • Documented new items visible to users: Doctor rake task, server bundle security options, generator improvements, and deprecation notice to remove config.generated_assets_dirs.

✏️ Tip: You can customize this high-level summary in your review settings.

Adds comprehensive documentation for upgrading from React on Rails v16.0.x to v16.1.1:

- New release notes file: docs/upgrading/release-notes/16.1.0.md
  - Step-by-step upgrade instructions
  - New features: doctor rake task, server bundle security options
  - Generator improvements with modern TypeScript patterns
  - Deprecations and migration guidance
  - Common troubleshooting issues
  - Version compatibility matrix

- Updated docs/upgrading/upgrading-react-on-rails.md
  - Added quick upgrade summary for v16.1.x
  - Links to detailed release notes

Closes #1831

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 26, 2025

Walkthrough

Added and updated upgrade documentation for v16.1.x: a new release notes file with step-by-step upgrade workflow, features, deprecations, bug fixes, and troubleshooting; and an updated upgrading guide that adds a v16.1.x section, dependency instructions, and a deprecation note for config.generated_assets_dirs.

Changes

Cohort / File(s) Summary
Release notes (new)
docs/upgrading/release-notes/16.1.0.md
New release notes describing upgrade steps from 16.0.x to 16.1.x, dependency updates (gem/npm), generator usage, the new doctor rake task, server bundle security options, deprecations, bug fixes, and troubleshooting.
Upgrade guide (updated)
docs/upgrading/upgrading-react-on-rails.md
Added "Upgrading to v16.1.x (from v16.0.x)" section with gem/npm version sync instructions, install commands, reference to the release notes, and deprecation guidance to remove config.generated_assets_dirs. Existing v16 upgrade content retained.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

  • Verify dependency version numbers (gem and npm) and install command accuracy.
  • Confirm deprecation text for config.generated_assets_dirs is correct and not missing migration guidance.
  • Check consistency between the release-notes file and the upgrading guide (steps, commands, troubleshooting).

Possibly related PRs

Suggested reviewers

  • Judahmeek
  • Romex91

Poem

🐰 From sixteen point oh to one dot one I bound,
Notes and steps and fixes all laid down,
Gems and npm in tidy sync,
Run the generator, give docs a wink—
Hop on, test, and wear the crown! 🥕📘

Pre-merge checks and finishing touches

✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: adding an upgrade guide for upgrading from v16.0.x to v16.1.1.
Linked Issues check ✅ Passed The PR addresses most core requirements from #1831: upgrade steps, generator improvements, version compatibility matrix, important notes, and troubleshooting guidance are all documented in the new release notes file.
Out of Scope Changes check ✅ Passed All changes are directly related to the upgrade guide objective; modifications to two documentation files align with the PR's stated purpose of adding comprehensive upgrading documentation.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch jg/upgrade-guide-16.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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
docs/upgrading/release-notes/16.1.0.md (1)

188-188: Add language specification to fenced code blocks.

Lines 188 and 196 contain fenced code blocks without language identifiers. Per markdown best practices, these should specify the language to enable proper syntax highlighting.

- ```
+ ```bash
  ERROR: You have uncommitted changes
- ```
+ ```bash
- ```
+ ```bash
  # Check versions
  bundle show shakapacker
  yarn list shakapacker  # or npm ls shakapacker
- ```
+ ```bash

Also applies to: 196-196

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 16b3908 and d9a6e91.

📒 Files selected for processing (2)
  • docs/upgrading/release-notes/16.1.0.md (1 hunks)
  • docs/upgrading/upgrading-react-on-rails.md (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*

📄 CodeRabbit inference engine (CLAUDE.md)

ALWAYS ensure files end with a newline character before committing/pushing

Files:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.md
🧠 Learnings (6)
📓 Common learnings
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG.md : Update `/CHANGELOG.md` for user-visible changes (features, bug fixes, breaking changes, deprecations, performance improvements) to the open-source React on Rails gem and npm package
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG*.md : Use changelog format: `[PR 1818](https://github.com/shakacode/react_on_rails/pull/1818) by [username](https://github.com/username)` (no hash in PR number)
📚 Learning: 2025-11-25T08:05:17.804Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG.md : Update `/CHANGELOG.md` for user-visible changes (features, bug fixes, breaking changes, deprecations, performance improvements) to the open-source React on Rails gem and npm package

Applied to files:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.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:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.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:

  • docs/upgrading/release-notes/16.1.0.md
📚 Learning: 2025-11-25T08:05:17.804Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG*.md : Use changelog format: `[PR 1818](https://github.com/shakacode/react_on_rails/pull/1818) by [username](https://github.com/username)` (no hash in PR number)

Applied to files:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.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:

  • docs/upgrading/release-notes/16.1.0.md
🪛 markdownlint-cli2 (0.18.1)
docs/upgrading/release-notes/16.1.0.md

188-188: Fenced code blocks should have a language specified

(MD040, fenced-code-language)


196-196: 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). (1)
  • GitHub Check: claude-review
🔇 Additional comments (4)
docs/upgrading/upgrading-react-on-rails.md (2)

24-73: Well-structured v16.1.x upgrade section with clear navigation.

The section appropriately links to the detailed release notes as the authoritative source while providing a quick summary and streamlined upgrade steps here. The progression (dependencies → install → generator → deprecations) follows best practices. Dependency versions are consistent across both files.


1-473: Ensure file ends with a newline character.

Per coding guidelines, all files must end with a newline character before committing. Please verify this file ends with a trailing newline.

docs/upgrading/release-notes/16.1.0.md (2)

1-244: Comprehensive and well-organized release notes covering all upgrade objectives.

The documentation effectively covers all requirements from issue #1831: step-by-step upgrade workflow, new features (doctor command, server bundle security), deprecations with migration guidance, bug fixes with PR references (correctly formatted without hash), security enhancements, version compatibility matrix, and thorough troubleshooting section. The structure progresses logically from upgrade steps to features to troubleshooting, making it user-friendly.


1-244: Ensure file ends with a newline character.

Per coding guidelines, all files must end with a newline character before committing. Please verify this file ends with a trailing newline.

@justin808
Copy link
Member Author

@claude review this PR.

@claude
Copy link

claude bot commented Dec 5, 2025

Claude finished @justin808's task —— View job


Review of PR #2130: Add upgrade guide for v16.0.x to v16.1.1

Todo List

  • Read the new release notes file (docs/upgrading/release-notes/16.1.0.md)
  • Read the updated upgrade guide (docs/upgrading/upgrading-react-on-rails.md)
  • Review technical accuracy of upgrade steps
  • Check markdown formatting and internal links
  • Verify alignment with repository guidelines (CLAUDE.md)
  • Provide comprehensive review feedback

Review Summary

This is excellent documentation that comprehensively addresses issue #1831. The upgrade guide is thorough, well-organized, and follows best practices. I found only minor issues that should be addressed.

✅ Strengths

  1. Complete Coverage: Addresses all requirements from issue Documentation: Add upgrade guide for v16.0.x to v16.1.1 #1831:

    • Step-by-step upgrade workflow ✓
    • New features documentation (doctor command, server bundle security) ✓
    • Deprecation notices with migration guidance ✓
    • Bug fixes with proper PR references ✓
    • Version compatibility matrix ✓
    • Comprehensive troubleshooting section ✓
  2. Excellent Structure: Logical progression from upgrade steps → new features → deprecations → bug fixes → troubleshooting

  3. Technical Accuracy: Version numbers are consistent across both files, dependency requirements are clearly stated

  4. User-Friendly: Clear examples, code blocks with proper context, helpful warnings and notes

  5. Repository Compliance:

    • ✅ Both files end with newline characters (CLAUDE.md requirement)
    • ✅ PR reference format is correct: [PR 1818](...) (no hash symbol)
    • ✅ All internal documentation links are valid

🔍 Issues to Address

1. Missing Language Specifications on Code Blocks (Lines 188-190, 196-198)

Location: docs/upgrading/release-notes/16.1.0.md

Two error message code blocks are missing language specifications:

Line 188-190:

-```
+```text
ERROR: You have uncommitted changes

Line 196-198:

-```
+```text
Shakapacker gem and node package versions do not match

Why: Markdown best practices require language specs for syntax highlighting. Use text for plain error messages.

Also flagged by: CodeRabbit's markdownlint check

2. Minor: Consider Adding Example for v16.1.1 Specific Bug Fix

Location: docs/upgrading/release-notes/16.1.0.md:153

The RSC manifest bug fix mentions "improved configuration flexibility" but doesn't show users how to configure it. Consider adding a brief example:

# config/initializers/react_on_rails.rb
ReactOnRails.configure do |config|
  # The manifest path is now correctly resolved from:
  config.server_bundle_js_file
  # instead of being hardcoded
end

This is optional but would help users understand the practical impact.

📋 Verification Checklist

  • Markdown renders correctly (verified all referenced files exist)
  • Internal links work:
    • ../../api-reference/configuration.md
    • ../../deployment/troubleshooting.md
    • ../../deployment/troubleshooting-build-errors.md
    • ../core-concepts/render-functions-and-railscontext.md
    • release-notes/16.1.0.md
  • Technical accuracy of upgrade steps (looks good)
  • Version numbers consistent (16.1.1, shakapacker 8.2.0)
  • Changelog format compliance (PR references use correct format)
  • Files end with newlines (both files ✓)

📝 Recommendations

  1. Fix the two code blocks without language specs (lines 188, 196) - this is the only required change
  2. Consider adding a configuration example for the v16.1.1 RSC fix (optional enhancement)

🎯 Verdict

Approve with minor fix requested: The documentation is comprehensive and valuable. Only the missing language specs on two code blocks need to be fixed before merging. This is a trivial fix that takes seconds.

Great work on creating such thorough upgrade documentation! This will save users significant time and confusion.


| Branch: jg/upgrade-guide-16.1

@justin808 justin808 added the AI_ON label Dec 5, 2025
- Use exact versions in examples (not ~>)
- Remove package manager-specific commands (support all)
- Reduce verbosity for minor/patch release upgrade
- Focus on essential information
Copy link
Contributor

@coderabbitai coderabbitai bot left a 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)
docs/upgrading/upgrading-react-on-rails.md (1)

1-334: Ensure file ends with a newline character.

The file must end with a newline per coding guidelines.

Verify that a newline character is present at the end of the file (after the final content on line 334).

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d9a6e91 and 6409951.

📒 Files selected for processing (2)
  • docs/upgrading/release-notes/16.1.0.md (1 hunks)
  • docs/upgrading/upgrading-react-on-rails.md (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
**/*

📄 CodeRabbit inference engine (CLAUDE.md)

ALWAYS ensure files end with a newline character before committing/pushing

Files:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.md
🧠 Learnings (8)
📓 Common learnings
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG.md : Update `/CHANGELOG.md` for user-visible changes (features, bug fixes, breaking changes, deprecations, performance improvements) to the open-source React on Rails gem and npm package
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG*.md : Use changelog format: `[PR 1818](https://github.com/shakacode/react_on_rails/pull/1818) by [username](https://github.com/username)` (no hash in PR number)
📚 Learning: 2025-11-25T08:05:17.804Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG.md : Update `/CHANGELOG.md` for user-visible changes (features, bug fixes, breaking changes, deprecations, performance improvements) to the open-source React on Rails gem and npm package

Applied to files:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.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:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.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:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.md
📚 Learning: 2025-11-25T08:05:17.804Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG*.md : Use changelog format: `[PR 1818](https://github.com/shakacode/react_on_rails/pull/1818) by [username](https://github.com/username)` (no hash in PR number)

Applied to files:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.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:

  • docs/upgrading/release-notes/16.1.0.md
  • docs/upgrading/upgrading-react-on-rails.md
📚 Learning: 2025-11-25T08:05:17.804Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to lib/react_on_rails/*.rb : Create RBS signature files for new Ruby files in `lib/react_on_rails/` by adding corresponding `.rbs` file in `sig/react_on_rails/`, adding to Steepfile, and validating before committing

Applied to files:

  • docs/upgrading/release-notes/16.1.0.md
📚 Learning: 2025-11-25T08:05:17.804Z
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: The `react_on_rails_pro/` directory has its own Prettier/ESLint configuration and must be linted separately

Applied to files:

  • docs/upgrading/release-notes/16.1.0.md
⏰ 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). (1)
  • GitHub Check: claude-review
🔇 Additional comments (1)
docs/upgrading/release-notes/16.1.0.md (1)

64-64: Add author attribution to PR reference.

Per changelog format conventions, PR references should include author attribution.

Apply this diff to add the missing author information:

-- Fixed RSC manifest file path resolution ([PR 1818](https://github.com/shakacode/react_on_rails/pull/1818))
+- Fixed RSC manifest file path resolution ([PR 1818](https://github.com/shakacode/react_on_rails/pull/1818) by [@username](https://github.com/username))

Please replace @username with the actual GitHub username of the PR author. Based on learnings, this is the standard format used in the React on Rails changelog.

⛔ Skipped due to learnings
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG*.md : Use changelog format: `[PR 1818](https://github.com/shakacode/react_on_rails/pull/1818) by [username](https://github.com/username)` (no hash in PR number)
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to /CHANGELOG.md : Update `/CHANGELOG.md` for user-visible changes (features, bug fixes, breaking changes, deprecations, performance improvements) to the open-source React on Rails gem and npm package
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Distinguish hypothetical fixes from confirmed fixes in commit messages and PR descriptions
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to lib/react_on_rails/*.rb : Create RBS signature files for new Ruby files in `lib/react_on_rails/` by adding corresponding `.rbs` file in `sig/react_on_rails/`, adding to Steepfile, and validating before committing
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.
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: Applies to sig/react_on_rails/**/*.rbs : In RBS type signature files, define type signatures that correspond to Ruby files in `lib/react_on_rails/`
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.
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.
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.
Learnt from: CR
Repo: shakacode/react_on_rails PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-25T08:05:17.804Z
Learning: The `react_on_rails_pro/` directory has its own Prettier/ESLint configuration and must be linted separately
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.

Comment on lines +1 to +80
# React on Rails 16.1.x Release Notes

## Upgrading from 16.0.x to 16.1.x

Update your gem and npm package versions:

```ruby
# Gemfile
gem "react_on_rails", "16.1.1"
gem "shakapacker", "8.2.0"
```

```json
// package.json
{
"dependencies": {
"react-on-rails": "16.1.1",
"shakapacker": "8.2.0"
}
}
```

Then run `bundle install` and your package manager's install command.

**Important:** The shakapacker gem and npm package versions must match exactly.

## New Features in v16.1.0

### Doctor Rake Task

New diagnostic command for troubleshooting setup issues:

```bash
rake react_on_rails:doctor
VERBOSE=true rake react_on_rails:doctor # For detailed output
```

### Server Bundle Security

New configuration options for enhanced server bundle security:

```ruby
# config/initializers/react_on_rails.rb
ReactOnRails.configure do |config|
# Directory for server bundle output (default: "ssr-generated")
config.server_bundle_output_path = "ssr-generated"

# When enabled, server bundles only load from private directories
config.enforce_private_server_bundles = true
end
```

### Generator Improvements

- Modern TypeScript patterns with better type inference
- Optimized tsconfig.json with `"moduleResolution": "bundler"`
- Enhanced Redux TypeScript integration
- Smart `bin/dev` defaults

## Bug Fixes

### v16.1.1

- Fixed RSC manifest file path resolution ([PR 1818](https://github.com/shakacode/react_on_rails/pull/1818))

### v16.1.0

- Fixed LoadError in `rake react_on_rails:doctor` when using packaged gem
- Fixed packs generator error when `server_bundle_js_file` is empty
- Fixed NoMethodError in environments without Shakapacker
- Fixed inconsistent Shakapacker version requirements

## Deprecations

Remove `config.generated_assets_dirs` from your configuration - asset paths are now automatically determined from `shakapacker.yml`.

## Related Resources

- [Changelog](https://github.com/shakacode/react_on_rails/blob/master/CHANGELOG.md)
- [Configuration Reference](../../api-reference/configuration.md)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Ensure file ends with a newline character.

The file must end with a newline per coding guidelines.

Add a newline at the end of line 80 (after the closing markdown content).

🤖 Prompt for AI Agents
docs/upgrading/release-notes/16.1.0.md lines 1-80: the file is missing a
trailing newline at EOF; open the file and add a single newline character after
the final line so the file ends with a newline, then save.

@claude
Copy link

claude bot commented Dec 5, 2025

Code Review: Upgrade Guide for v16.0.x to v16.1.1

Thank you for creating this comprehensive upgrade documentation! Overall, this is a well-structured and helpful guide for users upgrading from v16.0.x to v16.1.x. Below is my detailed feedback:


✅ Strengths

  1. Clear Structure: The release notes are well-organized with logical sections (Upgrading, New Features, Bug Fixes, Deprecations, Related Resources).

  2. Code Examples: Good use of code blocks showing exactly what users need to update in their Gemfile and package.json.

  3. Consistency with CHANGELOG: The content accurately reflects the information in CHANGELOG.md for v16.1.0 and v16.1.1.

  4. Helpful Context: The "Important" note about matching Shakapacker versions is valuable and prevents common mistakes.

  5. Working Links: Verified that the linked files exist (e.g., docs/api-reference/configuration.md).


📝 Suggestions for Improvement

1. Security Enhancements Missing

The CHANGELOG includes a detailed "Security Enhancements" section for v16.1.0:

  • Fixed command injection vulnerabilities (PR 1786)
  • Improved input validation (PR 1786)
  • Hardened DOM selectors with CSS.escape() for XSS protection (PR 1791)

Recommendation: Consider adding a "Security Enhancements" section to the release notes to highlight these important fixes, especially since security improvements are highly relevant to users.

2. Version Compatibility Matrix Missing

The PR description mentions "Version compatibility matrix" but this does not appear in the actual release notes file.

Recommendation: Consider adding a simple compatibility table showing supported Ruby, Node.js, Shakapacker, and React versions.

3. Generator Improvements Could Be More Specific

The generator improvements section (lines 53-58) lists features but does not clarify when users will see them.

Recommendation: Add a brief note that these improvements only affect newly generated code from rails g react_on_rails:install or component generators. Existing applications are unaffected.

4. Link Format and Attribution

Line 64 uses a different format than the CHANGELOG - missing author attribution.

Recommendation: For consistency and giving proper attribution, add author credits to match the CHANGELOG format used in the main project.

5. Common Upgrade Issues Section

The PR description mentions "Common troubleshooting issues" but these do not appear in the release notes.

Recommendation: Consider adding a "Common Upgrade Issues" section with solutions to known problems like Shakapacker version mismatches.

6. Pro License Features

The CHANGELOG has extensive "Pro License Features" section that is not mentioned in the release notes:

  • Core/Pro separation
  • Runtime license validation
  • Enhanced immediate hydration
  • License documentation

Recommendation: While these might be intended for Pro-only documentation, a brief note might help users understand what features require Pro.


🔍 Technical Accuracy

✅ All version numbers are accurate
✅ Configuration examples match current API
✅ Links to related documentation are correct
✅ Deprecation notice is clear and actionable
✅ Bug fix descriptions match CHANGELOG entries


🎯 Best Practices Compliance

✅ Follows project convention for release notes structure
✅ Placed in correct directory (docs/upgrading/release-notes/)
✅ Uses proper kebab-case filename (16.1.0.md)
✅ Links properly integrated into main upgrade guide
✅ File ends with newline (verified in diff)


📋 Test Plan Verification

From PR description:

  • Markdown renders correctly (verified via diff)
  • Internal links work (verified docs/api-reference/configuration.md exists)
  • Technical accuracy reviewed (compared with CHANGELOG.md)

Summary

This is high-quality documentation that will be very helpful for users upgrading to v16.1.x. The main suggestions are:

  1. Add Security Enhancements section (high priority for user awareness)
  2. Add Version Compatibility Matrix (mentioned in PR description but missing)
  3. Add author attributions for consistency with CHANGELOG format
  4. Clarify generator improvements only affect new generations
  5. Consider Common Upgrade Issues section if there are known pitfalls
  6. Brief mention of Pro features for completeness

The current version is ready to merge as-is, but these additions would make it even more comprehensive and user-friendly.

Great work on creating thorough upgrade documentation! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Documentation: Add upgrade guide for v16.0.x to v16.1.1

2 participants