Skip to content

docs: make React differences example-first - #354

Merged
trueadm merged 1 commit into
octanejs:mainfrom
openai-oss-forks:docs/351-example-first-react-differences
Jul 28, 2026
Merged

trueadm merged 1 commit into
octanejs:mainfrom
openai-oss-forks:docs/351-example-first-react-differences

Conversation

@domgan-oai

@domgan-oai domgan-oai commented Jul 28, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Make docs/differences-from-react.md genuinely example-first with 25 small, source-backed examples and compact decision tables.
  • Preserve the dependency-inference distinction documented in issue Clarify dependency inference for built-in hooks inside custom hooks #326 between direct built-in-hook dependency inference in compiler-processed .ts/.js custom hooks and the narrower inference of local, transparent custom-wrapper calls.
  • Correct the same distinction in the authoritative public website React migration guide so the two user-facing sources do not contradict one another.
  • Cover conditional slot-keyed hooks and loop exceptions; inferred, explicit, empty, and null dependencies; pure automatic and derived-value memoization; both state and reducer getters; native and controlled events; class composition; scheduling and concurrent use(); roots, lazy boundaries, refs, server rendering, streaming, and hydration.
  • Preserve the existing reconciler, scheduler, Suspense, controlled-input, diagnostics, and hydration guarantees without making claims about the unresolved separate JSX expressions run in different contexts depending on how the JSX is used #353 behavior.

Why

React users should be able to see Octane's real syntax, observable behavior, and compiler eligibility before having to reconstruct them from dense prose.

Closes #351.

Attribution

Adapted from Alec Larson's public example-first prototype, whose guide baseline is identical to current upstream main. The final GitHub-verified commit retains his Co-authored-by attribution and preserves subsequently clarified custom-hook behavior.

Validation

  • Exact locked [email protected] with the repository Markdown/MDX options: node node_modules/.pnpm/[email protected]/node_modules/prettier/bin/prettier.cjs --no-config --use-tabs --tab-width 2 --single-quote --print-width 100 --check docs/differences-from-react.md website/src/content/docs/differences-from-react.mdx.
  • node scripts/react-parity/check.mjs.
  • node scripts/workspace-packages.mjs --check.
  • node scripts/generate-parity-gaps.mjs --check.
  • node scripts/generate-binding-parity-gaps.mjs --check.
  • node scripts/generate-bindings-status.mjs --check.
  • node scripts/redact-audit/generate.mjs --check.
  • node scripts/check-changesets.js, node scripts/check-test-markers.mjs, node scripts/check-tsrx-module-decls.mjs, and node scripts/check-context-budget.mjs.
  • node --test scripts/react-parity/inventory-lib.test.mjs scripts/scaffold-react-port.test.mjs scripts/redact-audit/ledger-lib.test.mjs — 44 tests passed.
  • All relative documentation links, all 25 guide examples, required sections, even code-fence pairs, and git diff --check.
  • Full local pnpm format:check, pnpm typecheck, and pnpm test: a normal pnpm install --frozen-lockfile is blocked by the existing protected-registry HTTP 403 for the exact locked @tsrx/[email protected] tarball. The lockfile, parser, registry credentials, and source packages are unchanged; this upstream PR requests the normal GitHub Actions checks instead.

Risk

Documentation only: exactly two existing documentation files, no runtime/compiler changes, no generated-document rewrites, and no package changeset.

Adapt the public example-first prototype by Alec Larson to exact current upstream, preserve direct built-in versus custom-wrapper dependency inference, and keep the public React migration guide consistent.

Co-authored-by: Alec Larson <[email protected]>
@vercel

vercel Bot commented Jul 28, 2026

Copy link
Copy Markdown

@domgan-oai is attempting to deploy a commit to the Ripple Team Team on Vercel.

A member of the Team first needs to authorize it.

@trueadm
trueadm merged commit f34225c into octanejs:main Jul 28, 2026
17 of 24 checks passed
@domgan-oai domgan-oai mentioned this pull request Jul 28, 2026
8 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Proposal: make differences-from-react.md example-first

2 participants