feat(Form): expose submit function (#1186)

This commit is contained in:
Romain Hamel
2024-01-02 16:28:38 +01:00
committed by GitHub
parent d64cb8a6fd
commit 4a25a12390
3 changed files with 8 additions and 1 deletions

View File

@@ -203,6 +203,9 @@ componentProps:
## API
::field-group
::field{name="submit ()" type="Promise<void>"}
Triggers form submission.
::
::field{name="validate (path?: string, opts: { silent?: boolean })" type="Promise<T>"}
Triggers form validation. Will raise any errors unless `opts.silent` is set to true.
::
@@ -217,5 +220,5 @@ componentProps:
::
::field{name="errors" type="Ref<FormError[]>"}
A reference to the array containing validation errors. Use this to access or manipulate the error information.
::
::
::