Skip to content

Commit

Permalink
Mention Renaming of useFormState (#65934)
Browse files Browse the repository at this point in the history
The useFormState hook was renamed to useActionState in react 19. At this
moment react 19 is still in Canary, it would be hard for beginners to
realise this.

Mentioning the fact of it being renamed will ideally help new people.

---------

Co-authored-by: Sam Ko <sam@vercel.com>
  • Loading branch information
Arinji2 and samcx committed May 18, 2024
1 parent aae7776 commit 695aec9
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -444,6 +444,7 @@ export function Signup() {
> **Good to know:**
>
> - Before mutating data, you should always ensure a user is also authorized to perform the action. See [Authentication and Authorization](#authentication-and-authorization).
> - In earlier React Canary versions, this API was part of React DOM and called `useFormState`.
#### Optimistic updates
Expand Down

0 comments on commit 695aec9

Please sign in to comment.