Skip to content

docs: document useFormStatus with preventDefault and startTransition - #8709

Closed
Adityasonawane-sudo wants to merge 1 commit into
reactjs:mainfrom
Adityasonawane-sudo:docs/useFormStatus-8682
Closed

Adityasonawane-sudo wants to merge 1 commit into
reactjs:mainfrom
Adityasonawane-sudo:docs/useFormStatus-8682

Conversation

@Adityasonawane-sudo

Copy link
Copy Markdown

Fixes #8682

This PR updates the useFormStatus documentation to clarify that the pending state will also be true if a form submission handler uses event.preventDefault() alongside startTransition, not just when using the action prop.

Added a note in the "Usage" section to explain this behavior.

@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! 🙌

@aurorascharff

Copy link
Copy Markdown
Collaborator

Thanks for the contribution! The current reference now has a dedicated section covering useFormStatus with an onSubmit handler, including preventDefault() and startTransition. Closing this as covered by #8683.

This branch was successfully deployed

1 active deployment
Preview — 88146370 Deployed Oct 25, 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.

[Suggestion]: Document that useFormStatus works with a preventDefault-ed onSubmit + startTransition

3 participants