Skip to content

First input change after failed submit ignored with Next server actions #1571

@evaogbe

Description

@evaogbe

Describe the bug

In a form using Next server actions and validation after submitting an invalid input, the next character typed into the input is not shown. The input only shows from the second character on

Your minimal, reproducible example

https://stackblitz.com/edit/nextjs-dbp2u3qq?file=app%2Fexample-form.tsx

Steps to reproduce

  1. Press submit button
  2. Type a character into the input

Expected behavior

The first character typed should be seen in the input

How often does this bug happen?

Every time

Screenshots or Videos

No response

Platform

  • OS: MacOS
  • Browser: Chrome and Firefox

TanStack Form adapter

react-form

TanStack Form version

1.12.2

TypeScript version

5.2.2 and 5.8.3

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions