Skip to content

docs: fix stale docs links and help URLs#2850

Merged
justin808 merged 7 commits intomainfrom
jg-codex/docs-link-cleanup-pass-1
Mar 26, 2026
Merged

docs: fix stale docs links and help URLs#2850
justin808 merged 7 commits intomainfrom
jg-codex/docs-link-cleanup-pass-1

Conversation

@justin808
Copy link
Copy Markdown
Member

@justin808 justin808 commented Mar 26, 2026

Summary

This docs cleanup pass aligns repo docs and user-facing help output with the current published docs structure.

Changes in this PR:

  • replace stale docs-route references in runtime/help output with the current docs paths
  • replace legacy Pro wiki links and stale external references in OSS docs
  • document current ReactOnRails.render return behavior for React 18+ vs React 16/17
  • update internal contributor guidance to point at the canonical Pro docs home

Scope notes

Validation

Passed:

  • bundle exec rubocop react_on_rails/lib/react_on_rails/configuration.rb react_on_rails/lib/react_on_rails/doctor.rb react_on_rails/lib/react_on_rails/packer_utils.rb react_on_rails/lib/react_on_rails/packs_generator.rb react_on_rails/lib/react_on_rails/server_rendering_js_code.rb react_on_rails/lib/tasks/generate_packs.rake react_on_rails/spec/dummy/spec/packs_generator_spec.rb
  • git diff --name-only origin/main...HEAD | rg '\.md$' | xargs pnpm dlx [email protected] --check
  • git diff --check
  • custom local relative-link scan across the changed markdown files
  • curl -I -L checks for https://invite.reactrails.com, https://jsdoc.app/, and https://reactonrails.com/docs/pro/

Not run:

  • bundle exec rspec react_on_rails/spec/dummy/spec/packs_generator_spec.rb
    • blocked in this clean worktree because the dummy-app spec loads rails_helper from the dummy app environment and that bundle/setup is not present here

Note

Low Risk
Low risk: changes are limited to documentation text and user-facing help/error message URLs, with no behavioral code changes.

Overview
Updates docs and in-tool messaging to match the reorganized reactonrails.com documentation structure, replacing legacy wiki/old guide URLs across OSS guides, Pro references, and generator docs.

Clarifies the ReactOnRails.render API docs to reflect React 18+ root return behavior vs React 16/17, and adds guidance warning that repeated calls on the same DOM node are not deduplicated.

Refreshes community/support links (Slack invite, JSDoc) and updates several runtime error/help messages and corresponding specs to point at the new canonical doc routes.

Written by Cursor Bugbot for commit 296ecc1. This will update automatically on new commits. Configure here.

Summary by CodeRabbit

  • Documentation
    • Updated many guide links to the reorganized documentation site (including Pro docs and upgrade/migration paths).
    • Clarified API docs for render behavior across React versions and added guidance about repeated renders.
    • Replaced community Slack invite/link and updated external JSDoc reference.
    • Adjusted error/help message and test links to point to the correct docs.

@chatgpt-codex-connector
Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Mar 26, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: c3ccaf14-268a-4c82-88bf-ca7ba1029d37

📥 Commits

Reviewing files that changed from the base of the PR and between 8f02870 and 296ecc1.

📒 Files selected for processing (1)
  • docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md
✅ Files skipped from review due to trivial changes (1)
  • docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md

Walkthrough

This PR updates many documentation hyperlinks and in-code help/error message URLs across OSS docs, Ruby code, and tests—replacing legacy GitHub wiki and stale links with canonical reactonrails.com docs paths and corrected relative links; small JSDoc and Slack invite fixes included. (≤50 words)

Changes

Cohort / File(s) Summary
Top-level Guide
AGENTS_USER_GUIDE.md
Replaced Pro docs path ./docs/pro/react-on-rails-pro.md./docs/pro/home-pro.md in two sections.
OSS Core Concepts & Deployment
docs/oss/core-concepts/client-vs-server-rendering.md, docs/oss/core-concepts/how-react-on-rails-works.md, docs/oss/core-concepts/react-server-rendering.md, docs/oss/deployment/server-rendering-tips.md
Replaced legacy GitHub wiki Pro links with canonical https://reactonrails.com/docs/pro/ URLs.
OSS Configuration & Building Features
docs/oss/configuration/README.md, docs/oss/building-features/how-to-conditionally-server-render-based-on-device-type.md
Updated relative documentation paths to new docs structure (configuration, upgrading release notes).
OSS Getting Started & Troubleshooting
docs/oss/getting-started/common-issues.md, docs/oss/deployment/troubleshooting.md
Replaced Slack workspace URL https://reactrails.slack.comhttps://invite.reactrails.com.
API Reference & Style
docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md, docs/oss/api-reference/redux-store-api.md, docs/oss/misc/style.md
Rewrote ReactOnRails.render return-contract text and example for React 18 vs 16/17; updated @returns guidance and adjusted doc links; replaced JSDoc link.
Docs: Generator / Misc
docs/oss/api-reference/generator-details.md
Updated Pro overview link to ../../pro/home-pro.md.
Ruby: Configuration, Packer, Packs Generator, Server Rendering
react_on_rails/lib/react_on_rails/configuration.rb, react_on_rails/lib/react_on_rails/packer_utils.rb, react_on_rails/lib/react_on_rails/packs_generator.rb, react_on_rails/lib/react_on_rails/server_rendering_js_code.rb
Updated in-code error/help message URLs to new /docs/core-concepts/... paths and anchors; no logic changes.
Ruby: Doctor & Rake Tasks
react_on_rails/lib/react_on_rails/doctor.rb, react_on_rails/lib/tasks/generate_packs.rake
Rewrote diagnostic/info message links to new docs paths (configuration, rendering_extension, upgrading, server-rendering).
Tests
react_on_rails/spec/dummy/spec/packs_generator_spec.rb
Updated expected error-message URLs in specs to match new documentation URLs.
Small docs fixes
docs/oss/building-features/*, other single-file docs
Minor single-line hyperlink updates across multiple OSS docs (release notes path, JSDoc link, Slack invite).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

Poem

🐰 I hopped through docs at break of dawn,

Swapped old links for paths now drawn.
Breadcrumbs tidy, pages bright,
I left the docs a cleaner sight.
🥕✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 15.38% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title 'docs: fix stale docs links and help URLs' accurately and concisely summarizes the primary change: updating documentation links and URLs throughout the codebase and help messages.
Linked Issues check ✅ Passed The PR comprehensively addresses issue #2839 by replacing all legacy GitHub wiki Pro links in OSS overview pages with canonical URLs, and also updates numerous related documentation references throughout the codebase.
Out of Scope Changes check ✅ Passed All changes are within scope: documentation link updates across OSS guides, Pro references, error messages, and test assertions. The PR intentionally excludes files from concurrent PRs and focuses on documentation/help URL cleanup.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch jg-codex/docs-link-cleanup-pass-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.

Comment thread CHANGELOG.md
@greptile-apps
Copy link
Copy Markdown

greptile-apps Bot commented Mar 26, 2026

Greptile Summary

This PR is a focused documentation hygiene pass that aligns all in-repo links, runtime error messages, and user-facing help output with the current docs routing structure on reactonrails.com.\n\nKey changes:\n- URL modernisation in Ruby runtime output — five stale /docs/guides/... URLs in doctor.rb, packs_generator.rb, configuration.rb, packer_utils.rb, server_rendering_js_code.rb, and the Rake task are replaced with current reactonrails.com/docs/core-concepts/... and reactonrails.com/docs/configuration/ routes.\n- Pro docs pointerdocs/pro/react-on-rails-pro.md references in AGENTS_USER_GUIDE.md and several OSS docs are updated to docs/pro/home-pro.md, which exists in the repository.\n- React 18+ accuracyrails-view-rendering-from-inline-javascript.md now correctly documents that ReactOnRails.render returns a React root under React 18+ (not a virtual DOM element), and the jQuery example is updated to call render() on each change rather than the incompatible setState.\n- Dead-link fixes — the docs/README.md changelog link pointed to a non-existent docs/oss/upgrading/changelog.md; it now resolves to the canonical CHANGELOG.md on GitHub. Legacy GitHub wiki links are replaced with reactonrails.com/docs/pro/.\n- Slack invite URL — three docs pages updated from reactrails.slack.com to invite.reactrails.com.\n- Test spec paritypacks_generator_spec.rb updated to match the new URLs in production error messages.

Confidence Score: 5/5

Safe to merge — all changes are documentation and string literals in error messages; no logic is modified.

Every changed Ruby file touches only string literals (URLs in error/help messages). All target paths were verified to exist in the repository or on the canonical docs site. The test spec was updated in lockstep with production code. The one P2 comment (relative path in a code-block comment) is a non-blocking style suggestion.

No files require special attention.

Important Files Changed

Filename Overview
react_on_rails/lib/react_on_rails/doctor.rb Updates five help-output URLs from stale /docs/guides/... paths to current routes; all new URLs map to existing docs sections.
react_on_rails/lib/react_on_rails/packs_generator.rb Three error-message URLs updated from legacy .md suffix guide path to current core-concepts route; test spec updated in sync.
react_on_rails/spec/dummy/spec/packs_generator_spec.rb URL literals in expected error strings updated to match production code changes; no logic changes.
docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Documents React 18+ render return type (Root vs. legacy instance) and updates the jQuery example to re-render instead of calling setState, which is incompatible with React 18 roots.
docs/README.md Replaces relative link to non-existent docs/oss/upgrading/changelog.md with absolute GitHub URL pointing to the actual CHANGELOG.
AGENTS_USER_GUIDE.md Updates Pro docs reference from docs/pro/react-on-rails-pro.md to the correct docs/pro/home-pro.md, which exists in the repository.
CHANGELOG.md Removes erroneous 2-space indentation from a continuation paragraph, improving Markdown rendering of the list item context.
docs/oss/configuration/README.md Fixes a stale relative release-notes link inside a code-block comment to point to the correct relative path, resolving to the existing docs/oss/upgrading/release-notes/16.0.0.md.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[User encounters error / reads docs] --> B{Source}
    B -->|Runtime Ruby error| C["packs_generator.rb / configuration.rb\npacker_utils.rb / server_rendering_js_code.rb"]
    B -->|rails react_on_rails:doctor| D["doctor.rb help output"]
    B -->|OSS Markdown docs| E["docs/oss/**/*.md"]
    B -->|AGENTS_USER_GUIDE / CHANGELOG| F["Repo-root docs"]

    C -->|old: /docs/guides/...| G["❌ Stale URL (404)"]
    C -->|new: /docs/core-concepts/...| H["✅ Current docs route"]

    D -->|old: /docs/guides/configuration/| I["❌ Stale URL"]
    D -->|new: /docs/configuration/| J["✅ Current docs route"]

    E -->|old: github.com/...wiki| K["❌ Legacy wiki redirect"]
    E -->|new: reactonrails.com/docs/pro/| L["✅ Pro docs landing"]

    E -->|old: reactrails.slack.com| M["❌ Stale Slack URL"]
    E -->|new: invite.reactrails.com| N["✅ Invite link"]
Loading

Reviews (1): Last reviewed commit: "docs: avoid overlap with active docs PRs" | Re-trigger Greptile

@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Mar 26, 2026

Review: Docs link alignment pass

Overall this is a clean, low-risk documentation PR. The URL/path updates all check out — I verified the target paths exist on disk and the new URLs match the current docs routing structure. A few observations:

One formatting regression

CHANGELOG.md line 228 — The See the [React on Rails Pro Configuration docs]... sentence was previously indented 2 spaces, making it a continuation paragraph of the - **Pro-Specific Configurations Moved to Pro Gem** list item. Removing the indent breaks it out of the list, producing an orphaned paragraph between two bullet items. See the inline comment for a one-line fix.

Notes (no action required)

  • docs/README.md changelog link — swapping ./oss/upgrading/changelog.md for the GitHub URL is reasonable; the two files are byte-for-byte identical, so the only practical difference is that readers land on GitHub rather than the rendered docs site.
  • React 18 return-value docs (rails-view-rendering-from-inline-javascript.md) — the update from component.setState(...) to a re-render call is a correct React 18 fix; setState is not available on React roots.
  • Ruby comment paths (e.g., docs/oss/configuration/README.md) — these are inside code blocks so they won't render as hyperlinks in any viewer; the relative path change is still accurate.
  • docs/pro/react-on-rails-pro.mdhome-pro.md — both files exist; home-pro.md appears to be the current landing page.

Outside of the CHANGELOG indentation fix this looks good to merge.

@justin808 justin808 changed the title Docs: align repo links with current docs routes docs: fix stale docs links and help URLs Mar 26, 2026
@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Mar 26, 2026

Review: docs: fix stale docs links and help URLs

Overall a clean, well-scoped maintenance pass. All link targets were verified.

What looks good:

Minor note:
In docs/oss/building-features/how-to-conditionally-server-render-based-on-device-type.md, the new link is inside a Ruby code block comment. Relative Markdown links inside fenced code blocks do not render as hyperlinks, so readers see the raw string. The old absolute GitHub URL was at least navigable if someone copied the snippet. Not a blocker.

Verdict: No security concerns, no broken paths, no logic errors. Ready to merge.

@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Mar 26, 2026

Review Summary

This is a clean, well-scoped docs cleanup pass. Changes are limited to link updates and documentation accuracy improvements with no functional behavior changes. The spec file is correctly updated to match new error message URLs.

Positive changes:

  • Replacing component.setState() with renderComponent() in the inline JS example is the right fix — calling setState externally is an anti-pattern that does not work with React 18+ functional components or hooks.
  • Slack invite URL update (reactrails.slack.com to invite.reactrails.com) and JSDoc domain update (usejsdoc.org to jsdoc.app) are correct.
  • All URL path migrations from /docs/guides/ to /docs/core-concepts/, /docs/configuration/, and /docs/upgrading/ look consistent and correct.
  • The relative link ../upgrading/release-notes/16.0.0.md in docs/oss/configuration/README.md resolves correctly.

Minor issue (inline comment posted):
The ReactDOM.render reference in the JSDoc 'Does this:' comment is the old React 16/17 API — it is slightly misleading now that the surrounding text correctly describes React 18+ returning a createRoot root object.

Verdict: Looks good with one minor suggestion.

@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Mar 26, 2026

Review: docs: fix stale docs links and help URLs

Overall: LGTM — clean, well-scoped docs cleanup. All link targets verified against the repo tree; spec fixtures correctly mirror the updated error messages in production code.

What looks good

  • All five URL path changes in Ruby source (configuration.rb, doctor.rb, packer_utils.rb, packs_generator.rb, server_rendering_js_code.rb) move from stale /guides/ and /guides/file-system-based-* URLs to real published routes, and the corresponding spec fixture strings in packs_generator_spec.rb are updated to match — no test/prod divergence.
  • Replacing component.setState({ value }) with a re-render call is the right correction for React 18+ where ReactDOM.createRoot(...).render() returns a Root object, not a component instance.
  • The Slack invite URL swap (reactrails.slack.cominvite.reactrails.com) and JSDoc domain fix (usejsdoc.orgjsdoc.app) are straightforward and correct.
  • Relative-path internal links (../configuration/README.md, ../upgrading/release-notes/16.0.0.md) both resolve to existing files in the tree.

One minor nit

In rails-view-rendering-from-inline-javascript.md, the updated top-level description and @returns JSDoc now accurately describe React 18+ vs 16/17 return values, but the inner block comment still says:

 * Does this:
 *   ReactDOM.render(React.createElement(HelloWorldApp, {name: "Stranger"}),
 *     document.getElementById('app'))

ReactDOM.render() is the legacy React 16/17 API (deprecated in React 18). Since the file now explicitly discusses React 18+ roots, this comment can mislead readers into thinking ReactOnRails still calls the legacy API internally. Consider noting that under React 18+ it uses ReactDOM.createRoot(el).render(), or simply remove the "Does this:" block since the surrounding text already covers the semantics.

This is non-blocking — the functional behavior of the example is correct regardless.

Comment thread docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Outdated
Copy link
Copy Markdown
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: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@AGENTS_USER_GUIDE.md`:
- Line 113: Update the stale documentation link found in generator-details.md
that still points to react-on-rails-pro.md; replace the old reference
("react-on-rails-pro.md") with the new consolidated documentation target
("home-pro.md") so the file consistently uses the migrated pro docs link
(matches the home-pro.md reference used elsewhere).

In `@docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md`:
- Around line 37-45: The example uses repeated calls to ReactOnRails.render via
renderComponent, but ClientRenderer contains a duplicate-render guard that skips
re-rendering the same DOM node when it is already mounted; update the docs
example to show the correct pattern: either call ReactOnRails.revive or
ReactOnRails.updateProps (or the documented API that forces prop updates)
instead of repeated ReactOnRails.render calls, or explain that renderComponent
must unmount/replace the node before calling ReactOnRails.render; reference
renderComponent, ReactOnRails.render, and ClientRenderer in the explanation so
readers know why the no-op occurs and which alternative API to use.
- Around line 20-21: Update the JSDoc `@returns` annotation to match the codebase
actual return union: replace the incorrect `{Root|ReactComponent|ReactElement}`
with `{void|Element|Component|Root}` so it correctly includes the legacy `void`
return and uses the actual type names `Element` and `Component`; change the
`@returns` line in
docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md
accordingly.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 684e6f36-3ae4-44e2-a586-0663fdc85623

📥 Commits

Reviewing files that changed from the base of the PR and between 7f34c8a and 02b5df4.

📒 Files selected for processing (19)
  • AGENTS_USER_GUIDE.md
  • docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md
  • docs/oss/api-reference/redux-store-api.md
  • docs/oss/building-features/how-to-conditionally-server-render-based-on-device-type.md
  • docs/oss/configuration/README.md
  • docs/oss/core-concepts/client-vs-server-rendering.md
  • docs/oss/core-concepts/how-react-on-rails-works.md
  • docs/oss/core-concepts/react-server-rendering.md
  • docs/oss/deployment/server-rendering-tips.md
  • docs/oss/deployment/troubleshooting.md
  • docs/oss/getting-started/common-issues.md
  • docs/oss/misc/style.md
  • react_on_rails/lib/react_on_rails/configuration.rb
  • react_on_rails/lib/react_on_rails/doctor.rb
  • react_on_rails/lib/react_on_rails/packer_utils.rb
  • react_on_rails/lib/react_on_rails/packs_generator.rb
  • react_on_rails/lib/react_on_rails/server_rendering_js_code.rb
  • react_on_rails/lib/tasks/generate_packs.rake
  • react_on_rails/spec/dummy/spec/packs_generator_spec.rb

Comment thread AGENTS_USER_GUIDE.md
Comment thread docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Outdated
Comment thread docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Outdated
@coderabbitai coderabbitai Bot added review-needed documentation docs-cleanup Documentation cleanup or migration P3 Parked priority labels Mar 26, 2026
Copy link
Copy Markdown
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

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md`:
- Line 3: The sentence describing the `render` method return value is too narrow
for React 16/17; update the line that currently reads "Under React 16/17, it
returns the rendered component instance" to mirror the JSDoc union on lines
22-23 by stating that legacy React (16/17) may return different values depending
on the render vs hydrate path (e.g., a component instance or other legacy return
types) so the docs align with the `render` method JSDoc.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: d7cd4d6b-8970-4340-a4aa-f7826c11fb59

📥 Commits

Reviewing files that changed from the base of the PR and between 02b5df4 and 6eb9d97.

📒 Files selected for processing (4)
  • docs/oss/api-reference/generator-details.md
  • docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md
  • docs/oss/building-features/how-to-conditionally-server-render-based-on-device-type.md
  • docs/oss/getting-started/common-issues.md
✅ Files skipped from review due to trivial changes (3)
  • docs/oss/api-reference/generator-details.md
  • docs/oss/getting-started/common-issues.md
  • docs/oss/building-features/how-to-conditionally-server-render-based-on-device-type.md

Comment thread docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Outdated
Comment thread docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Outdated
@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Mar 26, 2026

Review: #2850

Overall the link-cleanup work here is solid — the URL migrations from the old GitHub wiki and stale /docs/guides/ paths to the correct canonical routes are accurate, the relative-link fix in docs/oss/configuration/README.md resolves correctly, and the test expectations in packs_generator_spec.rb were updated to match the new error-message URLs.

One factual inaccuracy in the new API docs (see inline comment):

The paragraph added to docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md:

ReactOnRails.render skips duplicate renders for the same connected node, so calling it repeatedly on #root will be ignored unless that node is replaced first.

This is not supported by the code. The public ReactOnRails.render method in packages/react-on-rails/src/base/client.ts calls reactHydrateOrRender unconditionally — there is no deduplication guard there. The skip logic only lives in the internal renderElement function inside ClientRenderer.ts, which is used by the page-lifecycle path (renderAllComponents / renderComponent), not by the public API. Calling the public ReactOnRails.render twice on the same node will create a second root (React 18+) or trigger a second legacy render — it is not silently ignored.

Everything else looks good:

  • URL replacements (wiki → reactonrails.com, old /guides/ → correct segment, Slack join → invite link, usejsdoc.org → jsdoc.app) all check out.
  • The React 18+ vs 16/17 return-value clarification in the @returns JSDoc is accurate (verified against reactApis.cts).
  • Removing the jQuery setState example is correct — ReactDOM.render's return value had a setState under React 16/17 class components, but the root object returned by React 18 does not.
  • The docs/pro/home-pro.md target exists; react-on-rails-pro.md is also still present so old deep-links won't break immediately, but keeping home-pro.md as the primary target is appropriate.

justin808 added a commit that referenced this pull request Mar 26, 2026
## Summary

- replace stale generator/help links that still point at moved docs or
`blob/master` paths
- update scaffolded initializer comments to the current published
configuration/testing docs
- refresh the manual-render example page so its code-splitting link
points at the live docs page

## Scope notes

- Limited to generator/help/example URLs only
- Intentionally separate from #2850 and #2851 to keep review small
- No runtime behavior changes

## Validation

Passed:
- `bundle exec rubocop
react_on_rails/lib/react_on_rails/test_helper/webpack_assets_compiler.rb
react_on_rails/lib/react_on_rails/helper.rb
react_on_rails/lib/generators/react_on_rails/templates/base/base/config/initializers/react_on_rails.rb.tt`
- `git diff --check`
- `curl -I -L` checks showing `200` for:
  - `https://reactonrails.com/docs/api-reference/generator-details/`
-
`https://reactonrails.com/docs/building-features/dev-server-and-testing/`
-
`https://reactonrails.com/docs/building-features/testing-configuration/`
  - `https://reactonrails.com/docs/building-features/code-splitting/`
-
`https://github.com/shakacode/react_on_rails/blob/main/react_on_rails/spec/dummy/client/app/startup/ReactHelmetApp.server.jsx`

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Low risk: updates only documentation links in generator templates,
helper error messages, and dummy/example views, with no runtime logic
changes.
> 
> **Overview**
> Refreshes several stale documentation URLs to point at the current
`reactonrails.com` docs, including generator usage output and the
scaffolded `config/initializers/react_on_rails.rb` template comments.
> 
> Also updates in-code guidance links in `ReactOnRails::Helper` error
messages and `TestHelper::WebpackAssetsCompiler`, plus the dummy
manual-render example page’s code-splitting link, to avoid `blob/master`
and moved-doc paths.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
f1afee9. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
justin808 added a commit that referenced this pull request Mar 26, 2026
## Summary

- replace dead `https://pro.reactonrails.com` links with the live
canonical Pro docs landing page at `https://reactonrails.com/docs/pro/`
- update the one user-facing runtime warning in `ReactOnRails::Utils` to
stop sending users to the failing subdomain
- keep the scope limited to non-overlapping files outside the active
docs PRs

## Scope notes

- Supports shakacode/reactonrails.com#59
- Intentionally does not touch
`react_on_rails/lib/generators/react_on_rails/pro_setup.rb`, which is
already tracked by #2575
- Intentionally does not touch the stale `/pro` page content /
`docs/pro/react-on-rails-pro.md`, which is tracked by #2838
- Intentionally excludes files already being modified in active PRs:
#2610, #2651, #2675, #2831, and #2850

## Validation

Passed:
- `bundle exec rubocop react_on_rails/lib/react_on_rails/utils.rb`
- `git diff --check`
- `git diff --name-only origin/main...HEAD | rg '\.md$' | xargs pnpm dlx
[email protected] --check`
- custom local relative-link scan across the changed markdown files
- `curl -I -L` checks showing:
  - `https://reactonrails.com/docs/pro/` -> `200`
  - `https://pro.reactonrails.com` -> `500`

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Low risk: changes are documentation link updates plus a single
user-facing warning string, with no behavioral impact beyond directing
users to a new URL.
> 
> **Overview**
> Updates documentation to replace references to the dead
`https://pro.reactonrails.com` site with the canonical Pro landing page
at `https://reactonrails.com/docs/pro/` across the README and multiple
OSS docs.
> 
> Also updates the
`ReactOnRails::Utils.immediate_hydration_pro_install_warning` message to
point users at the new Pro docs URL when `immediate_hydration: true` is
used without the Pro gem.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
457f7d5. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Documentation**
* Updated React on Rails Pro documentation links across the README, API
references, feature guides, configuration documentation, migration
guides, release notes, and installation messages to consistently direct
users to the new centralized Pro documentation hub for improved
navigation and accessibility.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
@justin808
Copy link
Copy Markdown
Member Author

Addressed the remaining actionable review feedback on this PR.

  • Updated docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md in 8f028708 to correct the React 16/17 return-value wording and the guidance about repeated ReactOnRails.render calls.
  • The other still-open inline doc threads were already stale on-branch and are being resolved as already handled.

Copy link
Copy Markdown
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: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md`:
- Line 44: Edit the sentence that currently reads "so calling it again on
`#root` will invoke React again unless you unmount or replace that node first."
and remove the duplicated "again" so it reads more cleanly (e.g., "so calling it
on `#root` will invoke React unless you unmount or replace that node first.");
update the text where `#root` and React are referenced.
- Around line 42-44: The docs incorrectly state that repeated
ReactOnRails.render calls will re-invoke React on the same node; update the text
to reflect the implementation that guards against duplicate renders: clarify
that ReactOnRails.render ignores repeated calls on the same connected DOM node
(so the mounted React component continues to manage state/props and duplicate
calls are deduplicated), and add a note that unmounting or replacing the node is
required to force a new render; reference ReactOnRails.render and the example
node id like `#root` to locate the sentence to change.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 557a5072-babc-4513-88fc-e386f4278580

📥 Commits

Reviewing files that changed from the base of the PR and between 6eb9d97 and 8f02870.

📒 Files selected for processing (1)
  • docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md

Comment thread docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Outdated
Comment thread docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Outdated
Comment thread docs/oss/api-reference/rails-view-rendering-from-inline-javascript.md Outdated
@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Mar 26, 2026

Review

Overall: LGTM with one minor inconsistency to fix.

This is a clean, low-risk docs pass. All the URL updates are correct:

  • Old wiki links (github.com/shakacode/react_on_rails/wiki) → reactonrails.com/docs/pro/
  • Old /guides/ path prefix → current path structure (/core-concepts/, /configuration/, /upgrading/)
  • Stale .md file extensions removed from runtime-message URLs (avoids 404s on the live docs site)
  • reactrails.slack.cominvite.reactrails.com
  • usejsdoc.orgjsdoc.app

Verified:

  • docs/pro/home-pro.md exists — the AGENTS_USER_GUIDE.md and generator-details.md links are valid
  • docs/oss/upgrading/release-notes/16.0.0.md exists — the configuration/README.md relative link fix is correct
  • No remaining /guides/ URLs in the Ruby lib files
  • Spec expectations updated in sync with the Ruby error message changes ✓

One issue flagged inline: rails-view-rendering-from-inline-javascript.md still uses jQuery ($('#input'), .val()) in the code example even though the prose was updated to remove the jQuery framing. A vanilla JS equivalent would align the example with the new narrative.

@justin808 justin808 merged commit aa9a002 into main Mar 26, 2026
36 checks passed
@justin808 justin808 deleted the jg-codex/docs-link-cleanup-pass-1 branch March 26, 2026 07:03

For subsequent updates on the same DOM node, let the mounted React component manage its own
state or props flow. The public `ReactOnRails.render` API does not deduplicate repeated calls,
so calling it on `#root` will invoke React unless you unmount or replace that node first.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Minor notation nit: #root is CSS-selector syntax, but the API takes a bare DOM id string ('root'). Using 'root' would match the code example on line 38 and avoid any confusion.

Suggested change
so calling it on `#root` will invoke React unless you unmount or replace that node first.
so calling it on `'root'` will invoke React again unless you unmount or replace that node first.

@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Mar 26, 2026

Review

This is a clean, well-scoped docs pass. All the URL migrations check out and I verified the key technical claims.

Verified correct:

  • All /guides/ → current path structure (/core-concepts/, /configuration/, /upgrading/) changes are accurate
  • Old GitHub wiki Pro links → reactonrails.com/docs/pro/
  • reactrails.slack.cominvite.reactrails.com
  • usejsdoc.orgjsdoc.app
  • docs/pro/home-pro.md exists; react-on-rails-pro.md is also still present so old deep-links remain valid ✓
  • Relative link fix in docs/oss/configuration/README.md: ../upgrading/release-notes/16.0.0.md resolves correctly ✓
  • Spec expectations in packs_generator_spec.rb updated in sync with Ruby error message URL changes ✓

On the deduplication statement (re: CodeRabbit's open request-for-changes): the current wording — "The public ReactOnRails.render API does not deduplicate repeated calls" — is factually correct. Traced the call path: base/client.ts#renderreactHydrateOrRenderreactRender/reactHydrate with no guard. The deduplication via renderedRoots.get(domNodeId) lives only in the internal renderElement function in ClientRenderer.ts (the page-lifecycle path), not in the public API. CodeRabbit's suggestion to say it does deduplicate would be inaccurate.

One minor notation nit left inline (CSS selector #root vs bare id string 'root'). Otherwise LGTM.

justin808 added a commit that referenced this pull request Mar 27, 2026
…olve-2833

* origin/main:
  docs: fix profiling node renderer command (#2863)
  generators: point Pro install fallback to upgrade guide (#2868)
  Add RSC Flight payload optimization guide (Article 7) (#2827)
  Migrate from deprecated Async::Variable to Async::Promise (#2832)
  docs: turn pro quick start into a gateway (#2862)
  Fix upload-assets endpoint duplicating bundles across directories (#2768)
  docs: fix stale docs links and help URLs (#2850)
  docs: replace dead pro.reactonrails.com links (#2851)
  docs: refresh generator and helper URLs (#2852)
  Add standalone RSC upgrade guide for existing Pro apps (#2831)
  Raise docs version floor to 16.4.0 in install/demo guidance (#2610)

# Conflicts:
#	CHANGELOG.md
justin808 added a commit that referenced this pull request Mar 27, 2026
…olve-2834

* origin/main:
  docs: fix profiling node renderer command (#2863)
  generators: point Pro install fallback to upgrade guide (#2868)
  Add RSC Flight payload optimization guide (Article 7) (#2827)
  Migrate from deprecated Async::Variable to Async::Promise (#2832)
  docs: turn pro quick start into a gateway (#2862)
  Fix upload-assets endpoint duplicating bundles across directories (#2768)
  docs: fix stale docs links and help URLs (#2850)
  docs: replace dead pro.reactonrails.com links (#2851)
  docs: refresh generator and helper URLs (#2852)

# Conflicts:
#	CHANGELOG.md
#	react_on_rails/lib/react_on_rails/utils.rb
justin808 added a commit that referenced this pull request Mar 27, 2026
…olve-2849

* origin/main:
  docs: fix profiling node renderer command (#2863)
  generators: point Pro install fallback to upgrade guide (#2868)
  Add RSC Flight payload optimization guide (Article 7) (#2827)
  Migrate from deprecated Async::Variable to Async::Promise (#2832)
  docs: turn pro quick start into a gateway (#2862)
  Fix upload-assets endpoint duplicating bundles across directories (#2768)
  docs: fix stale docs links and help URLs (#2850)
  docs: replace dead pro.reactonrails.com links (#2851)
  docs: refresh generator and helper URLs (#2852)
  Add standalone RSC upgrade guide for existing Pro apps (#2831)
  Raise docs version floor to 16.4.0 in install/demo guidance (#2610)

# Conflicts:
#	CHANGELOG.md
justin808 added a commit that referenced this pull request Mar 27, 2026
…olve-2835

* origin/main: (21 commits)
  docs: fix profiling node renderer command (#2863)
  generators: point Pro install fallback to upgrade guide (#2868)
  Add RSC Flight payload optimization guide (Article 7) (#2827)
  Migrate from deprecated Async::Variable to Async::Promise (#2832)
  docs: turn pro quick start into a gateway (#2862)
  Fix upload-assets endpoint duplicating bundles across directories (#2768)
  docs: fix stale docs links and help URLs (#2850)
  docs: replace dead pro.reactonrails.com links (#2851)
  docs: refresh generator and helper URLs (#2852)
  Add standalone RSC upgrade guide for existing Pro apps (#2831)
  Raise docs version floor to 16.4.0 in install/demo guidance (#2610)
  Fix release script: require changelog, fix RC version computation (#2848)
  Bump version to 16.5.0
  Bump version to 16.5.0.rc.0
  Update CHANGELOG.md for 16.5.0.rc.0 (#2847)
  Docs: add memory leak prevention guide for Node Renderer SSR (#2845)
  Docs: fix RSC migration gaps found during real-world migration (#2842)
  Add common mistakes sections to RSC migration guides (#2826)
  fix: preserve runtime env vars across Bundler.with_unbundled_env (#2836)
  Skip Pro CI workflows for Dependabot PRs (#2825)
  ...

# Conflicts:
#	CHANGELOG.md
@justin808 justin808 mentioned this pull request Mar 28, 2026
2 tasks
justin808 added a commit that referenced this pull request Mar 28, 2026
## Summary

- Stamped `### [16.5.1] - 2026-03-27` with two Pro fixes (PRs #2872,
#2768)
- Removed the `### [16.5.0.rc.0]` section (was already released as
16.5.0 stable)
- Consolidated the 16.5.0 section with full entries (previously just
said "no changes from rc.0")
- Updated diff links at bottom of file

## Skipped PRs (docs/internal only)
#2856, #2860, #2857, #2859, #2864, #2870, #2863, #2868, #2827, #2862,
#2850, #2851, #2852, #2831, #2610, #2848

## Test plan
- [ ] Verify CHANGELOG.md formatting and diff links are correct
- [ ] Run `rake release` (no args) after merge to publish 16.5.1

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

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Low risk: changes are limited to `CHANGELOG.md` release notes and
version/compare links with no runtime code modifications.
> 
> **Overview**
> Documents the `16.5.1` release by adding a new section under
*Unreleased* with two **[Pro]** fixes (missing packaged rake tasks and
avoiding duplicated bundles during remote renderer asset uploads).
> 
> Cleans up the `16.5.0` entry by removing the `16.5.0.rc.0` section and
updating the compare-link footer so `unreleased` now starts from
`v16.5.1` and `16.5.0` compares from `v16.4.0`.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
9a6b224. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Documentation**
* Updated changelog to document version 16.5.1 release with consolidated
version history and updated comparison links.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: Claude Opus 4.6 (1M context) <[email protected]>
justin808 added a commit that referenced this pull request Mar 28, 2026
## Summary

- Stamped `### [16.5.1] - 2026-03-27` with two Pro fixes (PRs #2872,
#2768)
- Removed the `### [16.5.0.rc.0]` section (was already released as
16.5.0 stable)
- Consolidated the 16.5.0 section with full entries (previously just
said "no changes from rc.0")
- Updated diff links at bottom of file

## Skipped PRs (docs/internal only)
#2856, #2860, #2857, #2859, #2864, #2870, #2863, #2868, #2827, #2862,
#2850, #2851, #2852, #2831, #2610, #2848

## Test plan
- [ ] Verify CHANGELOG.md formatting and diff links are correct
- [ ] Run `rake release` (no args) after merge to publish 16.5.1

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

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Low risk: changes are limited to `CHANGELOG.md` release notes and
version/compare links with no runtime code modifications.
> 
> **Overview**
> Documents the `16.5.1` release by adding a new section under
*Unreleased* with two **[Pro]** fixes (missing packaged rake tasks and
avoiding duplicated bundles during remote renderer asset uploads).
> 
> Cleans up the `16.5.0` entry by removing the `16.5.0.rc.0` section and
updating the compare-link footer so `unreleased` now starts from
`v16.5.1` and `16.5.0` compares from `v16.4.0`.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
9a6b224. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

* **Documentation**
* Updated changelog to document version 16.5.1 release with consolidated
version history and updated comparison links.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

Co-authored-by: Claude Opus 4.6 (1M context) <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs-cleanup Documentation cleanup or migration documentation P3 Parked priority review-needed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docs: replace legacy GitHub wiki Pro links in OSS overview pages

1 participant