Installation
INFO
This module requires Nuxt 3.7.0. If you must use an older Nuxt version, this module should work as long as you are using Nitro > 2.6.0 and h3 > 1.8.0.
You can use this package in any Nuxt project. Create a new project from scratch with the official Nuxt CLI
npx nuxi initpnpx nuxi inityarn dlx nuxi initbunx nuxi initInstall the form-actions module from NPM :
npm install @hebilicious/form-actions-nuxtpnpm add @hebilicious/form-actions-nuxtyarn add @hebilicious/form-actions-nuxtbun install @hebilicious/form-actions-nuxtAdd it to modules in your nuxt.config:
// nuxt.config.ts
export default defineNuxtConfig({
modules: ["@hebilicious/form-actions-nuxt"]
})That's it ! You can now use form actions in your Nuxt project.
Troubleshooting
Before reaching for issues and discussions, please try one of the starter templates available here.
If you are unable to make it work, have a look at the existing issues and discussions!
Open a new issue if you have a bug or a feature request, and a discussion if you have a question.
Roadmap
- Vue query integration
- Vue macro to automatically bind v-enhance to single forms
- overload useFormActions to accept multiple syntaxes and shorten the api
Feel free to open an issue or a discussion if you have any suggestion or feedback.