#What is the astro way to handle a form submission?

1 messages · Page 1 of 1 (latest)

rose sail
#

I'm wanting to post a form, run some js, and redirect to another astro page with some state set. What's the astro way to do this?

abstract pollen
#

Astro renders the form statically.

If you'd like an interactive form, you could use a frontend framework like Vue or React.

If you want to handle form data, I would recommend a serverless endpoint, or another service to send the data to as the form action="".

safe flame