Skip to content

Conversation

@ryan953
Copy link
Member

@ryan953 ryan953 commented Nov 12, 2025

This route only uses children, so it's quick to convert to <Outlet>

@ryan953 ryan953 changed the title chore: Remove deprecatedRouteProps for /pull chore: Remove deprecatedRouteProps for /pull/ Nov 12, 2025
@ryan953 ryan953 requested a review from rbro112 November 12, 2025 13:59
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Nov 12, 2025
@ryan953 ryan953 requested a review from a team November 12, 2025 13:59
@ryan953
Copy link
Member Author

ryan953 commented Nov 12, 2025

@sentry review

Comment on lines 26 to 35
)}
>
<NoProjectMessage organization={organization}>
<UrlParamBatchProvider>{children}</UrlParamBatchProvider>
<UrlParamBatchProvider>
<Outlet />
</UrlParamBatchProvider>
</NoProjectMessage>
</Feature>
);
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The migration from a children prop to React Router v6's <Outlet /> component is correctly implemented. The component now properly renders nested routes. However, ensure that the UrlParamBatchProvider is the appropriate context wrapper for the <Outlet />. If this provider was previously wrapping only specific child components, verify that wrapping the entire <Outlet /> is the intended behavior and won't cause unintended side effects on all nested routes.
Severity: MEDIUM

🤖 Prompt for AI Agent

Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: static/app/views/pullRequest/index.tsx#L1-L35

Potential issue: The migration from a children prop to React Router v6's `<Outlet />`
component is correctly implemented. The component now properly renders nested routes.
However, ensure that the `UrlParamBatchProvider` is the appropriate context wrapper for
the `<Outlet />`. If this provider was previously wrapping only specific child
components, verify that wrapping the entire `<Outlet />` is the intended behavior and
won't cause unintended side effects on all nested routes.

Did we get this right? 👍 / 👎 to inform future reviews.

};

function PullRequestContainer({children}: Props) {
export default function PullRequestContainer() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change from a named export to a default export is appropriate. However, verify that no other files are importing PullRequestContainer as a named import (e.g., import { PullRequestContainer }). Search the codebase for any named imports to ensure compatibility. Only the route configuration should reference this component via default export.
Severity: MEDIUM

🤖 Prompt for AI Agent

Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: static/app/views/pullRequest/index.tsx#L11

Potential issue: The change from a named export to a default export is appropriate.
However, verify that no other files are importing `PullRequestContainer` as a named
import (e.g., `import { PullRequestContainer }`). Search the codebase for any named
imports to ensure compatibility. Only the route configuration should reference this
component via default export.

Did we get this right? 👍 / 👎 to inform future reviews.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants