Skip to content

fix(structuredEventData): Remove inline Wrapper component to satisfy React Compiler#120019

Closed
sentry[bot] wants to merge 1 commit into
masterfrom
seer/fix-static-component-definitions-recursive-data
Closed

fix(structuredEventData): Remove inline Wrapper component to satisfy React Compiler#120019
sentry[bot] wants to merge 1 commit into
masterfrom
seer/fix-static-component-definitions-recursive-data

Conversation

@sentry

@sentry sentry Bot commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

The Wrapper component in static/app/components/structuredEventData/recursiveStructuredData.tsx was defined inside the RecursiveStructuredData function's render body. This caused a static-component-definitions violation because React treats components defined during render as new identities on each render, leading to unnecessary unmounts/remounts and blocking React Compiler optimizations.

The Wrapper component was primarily used to prepend formattedObjectKey to its children. This change removes the Wrapper component entirely and directly inlines formattedObjectKey as the first child within the <Fragment> in each relevant return statement. This resolves the static component definition issue without altering the rendered output or component behavior.

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

Fixes CODING-CONVENTIONS-36Z

Comment @sentry <feedback> on this PR to have Autofix iterate on the changes.

@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Jul 19, 2026
@ryan953

ryan953 commented Jul 20, 2026

Copy link
Copy Markdown
Member

replaced by #120038

@ryan953 ryan953 closed this Jul 20, 2026
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.

1 participant