Skip to content
This repository was archived by the owner on Sep 23, 2026. It is now read-only.
This repository was archived by the owner on Sep 23, 2026. It is now read-only.

Update @toolpad/core to React 19 #4499

Closed

Description

@bharatkashyap
No description provided.

Activity

  1. converted this from a draft issue on Dec 2, 2024
  2. added
    internalBehind-the-scenes enhancement. Formerly called “core”.
    on Dec 2, 2024
  3. jy95 commented on Dec 7, 2024

    @jy95

    +1

  4. kirill-konshin commented on Dec 29, 2024

    @kirill-konshin

    At the very least the return from useActionState should be compatible with signIn prop of SignInPage:

    const [whatever, action, isPending] = useActionState(
      async (_, formData) => {
        // logic
      },
      {},
    );
    
    // this one works but emits error in console
    <SignInPage signIn={(provider, formData) => action(formData)} />
    
    // this one results in full screen error
    <SignInPage signIn={action} />

    Error: An async function was passed to useActionState, but it was dispatched outside of an action context. This is likely not what you intended. Either pass the dispatch function to an action prop, or dispatch manually inside startTransition

  5. suren-atoyan commented on Jan 3, 2025

    @suren-atoyan

    @oliviertassinari any plans on this?

  6. bharatkashyap commented on Jan 3, 2025

    @bharatkashyap
    CollaboratorAuthor

    At the very least the return from useActionState should be compatible with signIn prop of SignInPage:

    const [whatever, action, isPending] = useActionState(
      async (_, formData) => {
        // logic
      },
      {},
    );
    
    // this one works but emits error in console
    <SignInPage signIn={(provider, formData) => action(formData)} />
    
    // this one results in full screen error
    <SignInPage signIn={action} />

    Error: An async function was passed to useActionState, but it was dispatched outside of an action context. This is likely not what you intended. Either pass the dispatch function to an action prop, or dispatch manually inside startTransition

    @oliviertassinari any plans on this?

    Supporting useActionState, useFormStatus and other form related React 19 hooks is planned after the React 19 upgrade PR (#4488) is merged and released next week

  7. moved this from In progress to Completed in Toolpad public roadmapon Jan 10, 2025
  8. github-actions commented on Jan 10, 2025

    @github-actions

    This issue has been closed. If you have a similar problem but not exactly the same, please open a new issue.
    Now, if you have additional information related to this issue or things that could help future readers, feel free to leave a comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    integration: react 19About improving React 19 support.internalBehind-the-scenes enhancement. Formerly called “core”.

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions