Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

useFormState's permalink option changes form target #27302

Merged
merged 3 commits into from
Aug 29, 2023

Commits on Aug 28, 2023

  1. Rename useFormState url arg to permalink

    Communicates the intent a bit better
    acdlite committed Aug 28, 2023
    Configuration menu
    Copy the full SHA
    3319e8b View commit details
    Browse the repository at this point in the history
  2. useFormState's permalink option changes form target

    When the `permalink` option is passed to `useFormState`, and the form is
    submitted before it has hydrated, the permalink will be used as the target
    of the form action, enabling MPA-style form submissions.
    
    (Note that submitting a form without hydration is a feature of Server Actions;
    it doesn't work with regular client actions.)
    
    It does not have any effect after the form has hydrated.
    acdlite committed Aug 28, 2023
    Configuration menu
    Copy the full SHA
    c538193 View commit details
    Browse the repository at this point in the history

Commits on Aug 29, 2023

  1. Coerce permalink to string

    acdlite committed Aug 29, 2023
    Configuration menu
    Copy the full SHA
    3216b92 View commit details
    Browse the repository at this point in the history