Skip to content

Document ref as a createElement prop in React 19 - #8762

Open
smg99 wants to merge 1 commit into
reactjs:mainfrom
smg99:docs/create-element-ref-prop
Open

smg99 wants to merge 1 commit into
reactjs:mainfrom
smg99:docs/create-element-ref-prop

Conversation

@smg99

@smg99 smg99 commented Nov 17, 2026

Copy link
Copy Markdown
Contributor

Update the createElement parameters, return value, and caveats for React 19. A supplied ref is available as element.props.ref. React exposes key separately, and reading element.ref is deprecated.

Verified on React 19.0.0 that a supplied ref remains in the props, a numeric key is converted to a string, and the legacy element.ref accessor issues a deprecation warning. git diff --check passed.

@github-actions

Copy link
Copy Markdown

Size changes

Details

📦 Next.js Bundle Analysis for react-dev

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

This branch was successfully deployed

1 active deployment
Preview — 88641268 Deployed Nov 17, 2026 by vercel[bot]
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.

1 participant