feat: pass onComplete/onFail callbacks through createJobHooks useRun#155
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✅ Files skipped from review due to trivial changes (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthrough
Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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 |
…it.each Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Summary
createJobHooksのuseRunフックにonStart/onComplete/onFailコールバックを pass-through できるようにする(Issue feat: pass onComplete/onFail callbacks through createJobHooks useRun #139)Pick<UseJobRunClientOptions, 'onStart' | 'onComplete' | 'onFail'>としてUseJobRunClientOptionsから導出し型の重複を排除types.test.tsにuseRun型テスト追加create-job-hooks.test.tsxにコールバック動作テスト追加(onComplete / onFail / onStart 発火、rerender 後の重複発火なし)Usage
Test plan
onCompleteが run 完了時に正確に 1 回発火するonFailが run 失敗時に正確に 1 回発火するonStartが null → pending 遷移時に正確に 1 回発火し、leased への再遷移では発火しないuseRun(runId)オプションなしで従来通り動作するpnpm validate28/28 パスCloses #139
🤖 Generated with Claude Code
Summary by CodeRabbit
リリースノート
New Features
Tests