Skip to content

Conversation

@justinvdm
Copy link
Collaborator

This change consolidates duplicated types into a single source of truth. The RwContext, DocumentProps, and LayoutProps types were previously defined in both sdk/src/runtime/lib/router.ts and sdk/src/runtime/lib/rwContext.ts.

To resolve this, sdk/src/runtime/lib/rwContext.ts has been renamed to sdk/src/runtime/lib/types.ts to better reflect its broader content. The duplicate definitions in sdk/src/runtime/lib/router.ts have been removed, and all imports now point to the new types.ts file.

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Oct 9, 2025

Deploying redwood-sdk-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: d00fc65
Status: ✅  Deploy successful!
Preview URL: https://1e35dec0.redwood-sdk-docs.pages.dev
Branch Preview URL: https://fix-duplicate-rw-context-typ.redwood-sdk-docs.pages.dev

View logs

@justinvdm justinvdm merged commit 1b69ee2 into main Oct 9, 2025
6 checks passed
justinvdm added a commit that referenced this pull request Oct 13, 2025
This change consolidates duplicated types into a single source of truth. The `RwContext`, `DocumentProps`, and `LayoutProps` types were previously defined in both `sdk/src/runtime/lib/router.ts` and `sdk/src/runtime/lib/rwContext.ts`.

To resolve this, `sdk/src/runtime/lib/rwContext.ts` has been renamed to `sdk/src/runtime/lib/types.ts` to better reflect its broader content. The duplicate definitions in `sdk/src/runtime/lib/router.ts` have been removed, and all imports now point to the new `types.ts` file.
justinvdm added a commit that referenced this pull request Oct 13, 2025
We accidentally stopped exporting these types in #815
justinvdm added a commit that referenced this pull request Oct 23, 2025
We accidentally stopped exporting these types in #815
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.

2 participants