Customization
<SubmitButton/>
Customizable submit button component for Nuxt Auto Form.
Customization
To override the default submit button, create a new component and register it in app.config.ts
:
app.config.ts
export default defineAppConfig({
autoForm: {
submit: {
component: 'SubmitButton',
},
},
})
The component must be globally registered to work.
To do this, name your component with the
.global.vue
suffix, or place it in components/global/
directory.Fields
disabled
boolean
Boolean property that indicates whether at least one field is invalid.
Examples
MyForm.global.vue
<script setup lang="ts">
defineProps<{
disabled?: boolean
}>()
</script>
<template>
<UButton
type="submit"
color="neutral"
:disabled
class="w-full flex justify-center cursor-pointer"
label="My custom send button"
/>
</template>