What’s new in React 19

  • By convention, functions that use async transitions are called “Actions”.

    Actions automatically manage submitting data for you:

    • Pending state: Actions provide a pending state that starts at the beginning of a request and automatically resets when the final state update is committed.
    • Optimistic updates: Actions support the new useOptimistic hook so you can show users instant feedback while the requests are submitting.
    • Error handling: Actions provide error handling so you can display Error Boundaries when a request fails, and revert optimistic updates to their original value automatically.
    • Forms<form> elements now support passing functions to the action and formAction props. Passing functions to the action props use Actions by default and reset the form automatically after submission.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>