-
Notifications
You must be signed in to change notification settings - Fork 142
chore(rivetkit): specialize context types for better compiler errors #3669
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 12-22-fix_rivetkit_fix_c.client_not_respecting_correct_origin
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
2 Skipped Deployments
|
PR Review: Specialize Context Types for Better Compiler ErrorsSummaryThis PR refactors RivetKit's context type system to provide more specialized context types for different lifecycle hooks. This is a significant improvement that will provide better TypeScript developer experience through stronger type safety and clearer APIs. ✅ Strengths1. Well-Structured Type HierarchyThe new context hierarchy is clean and logical:
2. Type Safety ImprovementsThe use of 3. Clear DocumentationAdded JSDoc comments clarifying when properties are/aren't available in different contexts. 4. Proper Context SpecializationEach lifecycle hook now has a context that reflects what's actually available:
5. Good File Organization
🔍 Issues & Recommendations1. Type Casting Could Hide Runtime Errors
|
4040925 to
b716026
Compare
b716026 to
db47c49
Compare
96cb137 to
bf7663e
Compare
db47c49 to
e4a1e83
Compare
bf7663e to
81d8c74
Compare
e4a1e83 to
f96b9d8
Compare
49e0689 to
81d8c74
Compare
f96b9d8 to
e4a1e83
Compare
e4a1e83 to
f96b9d8
Compare
81d8c74 to
49e0689
Compare
49e0689 to
81d8c74
Compare
f96b9d8 to
e4a1e83
Compare

No description provided.