React Actions & useActionState
Define server and client actions, handle form submissions, and track pending states.
Welcome
In this lesson you will define React 19 Actions, use useActionState to manage form submission state, and handle pending and error states cleanly.
What Are React Actions?
Actions are async functions you pass to the form `action` prop (or button `formAction`). React 19 treats them specially: it tracks pending state, handles errors, and integrates with Transitions automatically.
All lessons in this course
- React Server Components Explained
- The use() Hook for Async Resources
- React Actions & useActionState
- useOptimistic for Instant Feedback