NOTFORM
Components

NotForm

The main wrapper component that provides form context to its children.

NotForm is a wrapper component that manages the form lifecycle and provides the form context to nested components like NotField and NotMessage.

Usage

form.vue
<script setup lang="ts">
const { id, submit } = useNotForm({ schema })
</script>

<template>
  <NotForm :id="id" @submit="submit">
    <!-- Form fields go here -->
    <button type="submit">Submit</button>
  </NotForm>
</template>

API

Props

PropTypeDefaultDescription
idstringRequiredThe unique form identifier obtained from useNotForm.
asstring'form'The HTML tag the component should render as.
asChildbooleanfalseWhether to render the component as its nearest child (renderless).

Slots

default

The default slot provides access to the entire form context.

Scope:

PropertyTypeDescription
stateRef<Input>Reactive form data.
errorsRef<Issue[]>Reactive validation issues.
isValidComputedRef<boolean>Form validity status.
isDirtyComputedRef<boolean>Form modification status.
submitFunctionForm submission handler.
resetFunctionForm reset handler.
......All other properties returned by useNotForm.