NgxsFormPluginModule
and include it in the imports.ngxsForm
directive with the path of your state object. We are passing the string path to ngxsForm
. The directive uses this path to connect itself to the store and setup bindings.ngxsFormDebounce: number
- Debounce the value changes to the form. Default value: 100
. Ignored if updateOn
is blur
or submit
.ngxsFormClearOnDestroy: boolean
- Clear the state on destroy of the form.actions
out of the box:UpdateFormStatus({ status, path })
- Update the form statusUpdateFormValue({ value, path, propertyPath? })
- Update the form value (or optionally an inner property value)UpdateFormDirty({ dirty, path })
- Update the form dirty statusSetFormDisabled(path)
- Set the form to disabledSetFormEnabled(path)
- Set the form to enabledSetFormDirty(path)
- Set the form to dirty (shortcut for UpdateFormDirty
)SetFormPristine(path)
- Set the form to pristine (shortcut for UpdateFormDirty
)ResetForm({ path, value? })
- Reset the form with or without the form value.UpdateFormValue
action that provides the ability to update nested form properties by supplying a propertyPath
parameter.ngxsForm
directive: