Nuxt Module
The official notform-nuxt module provides a first-class developer experience for using NotForm in Nuxt applications. It handles component and composable registration automatically.
Installation
The module is registered in the official Nuxt Modules Registry, meaning you can easily install it using the Nuxt CLI.
npx nuxi module add notform
pnpm dlx nuxi module add notform
bunx nuxi module add notform
yarn dlx nuxi module add notform
notform-nuxt and add it to the modules array in your nuxt.config.ts. You still need to install your preferred validation library (e.g., zod).pnpm add zod
Manual Setup
If you prefer to install manually, add the dependency:
pnpm add notform-nuxt
Then, add it to your nuxt.config.ts:
export default defineNuxtConfig({
modules: ['notform-nuxt'],
})
Features
Auto-imports
All core components and composables are available globally in your Vue files without any manual imports.
| Export | Type | Description |
|---|---|---|
useNotForm | Composable | The core form management composable. |
NotForm | Component | Context provider and <form> wrapper. |
NotField | Component | Renderless wrapper for single fields. |
NotMessage | Component | Error message renderer. |
NotArrayField | Component | Renderless wrapper for dynamic array fields. |
Type Safety
Types for NotFormInstance, UseNotFormConfig, and NotFieldProps are automatically injected into your project's global types for perfect IntelliSense.
Server-side Rendering (SSR)
NotForm is fully compatible with Nuxt's SSR engine. Form state and validation rules are safely executed on the server during the initial render without hydration mismatches.