Forked from: https://gist.github.com/mohitmamoria/91da6f30d9610b211248225c9e52bebe?permalink_comment_id=5155652 Why?: To add types and generics for a better DX.
Inertia.js ships with a fantastic form helper but it falls short when also using API/Axios calls in your project.
Here's a composable, built on top of the Inertia's form helper that hooks into it to replace the API calls with Axios.
To use, just replace useForm
with useAPIForm
.