docs(form): improve types

This commit is contained in:
Benjamin Canac
2025-04-09 12:06:41 +02:00
parent 626b023ddb
commit e6b1c238b9
7 changed files with 7 additions and 7 deletions

View File

@@ -14,7 +14,7 @@ const validate = (state: any): FormError[] => {
}
const toast = useToast()
async function onSubmit(event: FormSubmitEvent<any>) {
async function onSubmit(event: FormSubmitEvent<typeof state>) {
toast.add({ title: 'Success', description: 'The form has been submitted.', color: 'success' })
console.log(event.data)
}