Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface ValiditiyActionOptions

Options for FormupContext.validity.

Hierarchy

  • ValiditiyActionOptions

Index

Properties

Properties

Optional at

at: string | string[]

For which field to track the validity status.

If the element is a form it uses isValid and isDirty stores to determines the validity.

<input use:validity={{ at: 'email' }}>

If at is not provided and the element is not a form it defaults to:

  • the data attribute pathAt
  • the name attribute
  • the path of the element referenced by the for attribute
  • the id attribute

If the only option is at it can be used directly:

<input use:validity={'email'}>

If no field has been found it updates the validity for itself and all its children.

Optional classes

classes: Partial<ValidityCSSClasses>

Allow to override the used CSS classes.

Generated using TypeDoc