Skip to content

chore(frontend): React 18 → 19 への移行 (#464)#543

Merged
yu23ki14 merged 1 commit into
v3from
feat/issue-464-react19-migration
Jun 27, 2026
Merged

chore(frontend): React 18 → 19 への移行 (#464)#543
yu23ki14 merged 1 commit into
v3from
feat/issue-464-react19-migration

Conversation

@yu23ki14

Copy link
Copy Markdown
Member

Closes #464

概要

pkgs/frontend の React を 18 → 19 へ bump。公式 React 19 Upgrade Guide に沿って破壊的変更を確認し、Issue の方針どおり React 19 単体の bump に限定(新機能採用・forwardRef クリーンアップはスコープ外)。

パッケージ before after
react ^18.3.1 ^19.2.0
react-dom ^18.3.1 ^19.2.0
@types/react ^18.3.11 ^19.2.0
@types/react-dom ^18.3.0 ^19.2.0

差分は package.json 4行 + pnpm-lock.yaml のみ。

公式ガイドの破壊的変更チェック

コードベースを走査し、該当コードはいずれも存在せずコードmod不要:

  • ReactDOM.render / hydrate / unmountComponentAtNode / findDOMNode / createFactory → なし(entry.client.tsx は既に hydrateRoot 使用、React Router v7 管理)
  • 文字列 ref / propTypes / defaultProps(関数コンポーネント)→ なし
  • useFormStateuseActionState → 該当なし
  • 引数なし useRef() / ref コールバックの暗黙 return(@types/react 19 で型エラー化)→ typecheck で未検出=該当なし
  • forwardRef(3ファイル)は React 19 でも有効(deprecated のみ)。shadcn/ui を upstream に近く保つ方針に従い据え置き

依存の互換性

  • @privy-io/react-auth: peer react: "^18 || ^19"
  • react-day-picker / react-i18next: React 19 許容 ✅
  • 残る peer 警告(valtio→use-sync-external-store@ladle/react→react-inspector)は transitive かつ React 18 時点から既存

検証

  • ✅ TypeScript: エラーなし(react-router typegen && tsc --noEmit
  • ✅ vite dev サーバー起動を確認
  • ⚠️ ルート 200 / ウォレット接続・当番作成・サンクス送信・分配作成の回帰 / Cypress E2E は .env.local を要するためローカル未実施 → CI / レビュー環境で確認お願いします

補足

pnpm frontend buildapp/vite-polyfills/ssr-buffer.tsnode:buffer 外部化で失敗しますが、React 18 でも同一に再現する既存の問題で本 PR とは無関係。別途 Issue 化を推奨。

🤖 Generated with Claude Code

react / react-dom / @types/react / @types/react-dom を ^19.2.0 に bump。
公式 React 19 Upgrade Guide に沿って破壊的変更を確認し、該当コードは
なし(ReactDOM.render/hydrate/findDOMNode/文字列ref/propTypes/
defaultProps/useFormState はいずれも未使用、entry.client は既に
hydrateRoot 使用)。forwardRef は React 19 でも有効なため据え置き。

Privy(^18||^19) など主要ピアの React 19 対応を確認。typecheck パス。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@vercel

vercel Bot commented Jun 27, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
toban Error Error Jun 27, 2026 7:18am

Request Review

@yu23ki14
yu23ki14 changed the base branch from main to v3 June 27, 2026 07:18
@yu23ki14
yu23ki14 merged commit 1faa52b into v3 Jun 27, 2026
2 of 4 checks passed
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.

[Phase 1 follow-up] React 18 → 19 への移行

1 participant