Skip to content

@self-assert/react API

Components

FunctionDescription
FormFieldHandles the logic for a form field and its error message, given a DraftAssistant.
ErrorMessageComponent to display a DraftAssistant's broken rules.

Hooks

React hooks that act as DraftAssistant wrappers and trigger re-renders.

FunctionDescription
useDraftAssistantModelHook to get and set the model of a DraftAssistant, triggering a re-render whenever the model changes.
useBrokenRulesDescriptionsHook to get the descriptions of the broken rules reported by the DraftAssistant.

Others

Type AliasDescription
FormFieldProps-
ErrorMessageProps-