[form] pages dir support (#68333)
This PR adds support for using Form with pages dir. The functionality is a bit limited: - in pages dir, Form doesn't prefetch, because there's no notion of an instant loading state that we could prefetch - No support for server actions - pending indicators from `useFormStatus` do not work while navigating to the target page (planning to address this in https://github.com/vercel/next.js/pull/70681) But other than those things, Form should work. Both of these patterns are supported: - `<Form action="/foo/bar">` - `<Form action={clientAction}>` (if using a react version with `useActionState`)
Showing
Please
register
or
sign in
to comment