Components
Form
Form primitives.
Use Form to manage validation, values, and submission.
We'll never share your email.
import { Form, FormField, FormItem, FormLabel, FormControl, Input, FormDescription, FormMessage, Button } from '@tile-ui/vue';
export default function FormDemo() {
return (
<Form>
<FormField name="email">Registry install
pnpm dlx shadcn@latest add @tile-ui/formPackage usage
import { Form, FormField, FormLabel, FormControl, Input, FormMessage } from '@tile-ui/vue';
<Form>
<FormField name="email">
<FormLabel>Email</FormLabel>
<FormControl>
<Input />
</FormControl>
<FormMessage />
</FormField>
</Form>Highlights
useFormhook- Field, label, control, and message
- Resolver validation
Registry dependencies
| Item | Purpose |
|---|---|
form |
Component source and module styles |
core |
Framework-agnostic logic helpers |
styles |
Shared SCSS tokens and globals |
API reference
Form
| Prop | Type | Default |
|---|---|---|
defaultValues |
Record<string, unknown> |
— |
resolver |
(values: FormValues) => FormErrors | Promise<FormErrors> |
— |
form |
unknown |
— |